Comment
Comment by duckerude
I wouldn't endorse that code, but it does make sense. You can read it like this:
`for s in [0]` assigns 0 to `s`, as an initial value. `for s in [s + x]` adds `x` to `s`. Both instances of `s` are the same variable, there's no shadowing going on.