This is cool, but I'm far too much of a math nerd to not point out that this misses a subtle and important distinction between for-loops and summation notation.
For-loops imply an order of evaluation, but summation notation is purely declarative. The terms are ordered, yes, but not in the sense of evaluation.
Regular reminder to self
![]()