Hacker News new | ask | show | jobs
by nyrikki 854 days ago
Mutable global variables online work for linear code with no concurancy.

Having code be tree like or at least a DAG is how you resolve what is probably most easily visualized as dependency hell.

This is why many modern patterns try and steer people into having their domain logic centered and compromised of idempotent functions.

And while they didn't know why back then, it is why accounting has used immutable events for over 500 years.

The notion of free variable is another lens to think about it.