~/talk

Truly Functional Solutions to the Longest Uptrend Problem (Functional Pearl)

Talkat ICFP 2025 · 2025-10-12..10-18· [functional-programming]
links:none on file
links:none on file
slides:none on file

Replaces the array-based LIS implementation with purely functional structures, shows a first persistent-sequence version runs about 6× slower, then builds a practical solution using Huet's zipper, red‑black trees and a left‑spine/finger‑tree view so binary search becomes exponential search on the spine. Benchmarks show red‑black and left‑spine implementations match the imperative runtime in practice, and the finger‑tree variant gains adaptive linear behaviour on nearly‑sorted inputs, with code and artifacts available.

AI-written summary · about

  1. 0:00Functional solutions intro
  2. 1:25Imperative to functional
  3. 5:23Integer indices problem
  4. 6:10Zippers for position
  5. 7:58Binary search with zippers
  6. 11:20Longest uptrend with zippers
  7. 13:53Degenerate tree fix
  8. 16:47Red-black tree spine
  9. 19:19Finger trees and search
  10. 20:02Benchmark results
  11. 21:52Conclusion
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.