Advertisement
Guest User

Untitled

a guest
Mar 3rd, 2014
195
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. 2.0.0p247 :001 > array = ["hello world"]
  2.  => ["hello world"]
  3. 2.0.0p247 :002 >  array.map!{ |entry| entry.split[-1] }
  4.  => ["world"]
  5. 2.0.0p247 :003 > array
  6.  => ["world"]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement