[SOLVED]Range each function

Can someone explain me the each function the range class has? I just can't get it to work for me. ):
Its a simplified way of using:

  1. for i in [email hidden]
  2. #code
  3. end
  4.  
  5. #Instead you could do
  6. @array.each {|i| #code}
  7.  
  8. #An example of the use could be
  9. @sprite_back.each {|sprite| sprite.dispose}
Expand to see the code.


I think thats what you wanted to know :P?
Yeah, that's exactly what I wanted to know, thanks!

Original thread: https://www.hbgames.org/forums/viewtopic.php?t=76710