~/talk

Imperative vs Functional: Which one to Choose?

slides:none on file

Argues that imperative code (familiar, verbose, mutable) adds accidental complexity while functional code is declarative + higher-order functions and reads like the problem statement; demonstrates Java Streams, Collector.joining and a parallelStream gone wrong when a shared ArrayList is mutated (race conditions that “lose Nemo” / broke a mutual‑fund batch). States two purity rules—no visible mutation and no dependency on outside mutable state—and shows exceptions must be modeled as data (Either) not thrown. Recommends prototyping both approaches.

AI-written summary · about

  1. 0:00Choosing the right tool
  2. 3:51Imperative style explained
  3. 12:10Declarative style approach
  4. 15:45Functional style defined
  5. 17:30Benefits of functional style
  6. 22:50Avoiding programming bias
  7. 27:06Purity and side effects
  8. 38:41Handling exceptions
  9. 50:00Conclusion and prototyping
~/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.