Hacker News new | past | comments | ask | show | jobs | submit login

    a = 0
    [1, 2, 3].each { |a| }
    a # => 3



Ah, thanks for the clarification. I guess that means there are at least two odd things about scoping in 1.8 loops.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: