F
Fredrik Jagenheim
Given this array:
foo = %w { FOO BAR baz biz }
How do I make all the entries uppercase in a short and readable way?
The (to me) obvious solution won't work:
foo.map! { |x| x.upcase! }
as upcase returns nil if it doesn't have anything to upcase...
//F
foo = %w { FOO BAR baz biz }
How do I make all the entries uppercase in a short and readable way?
The (to me) obvious solution won't work:
foo.map! { |x| x.upcase! }
as upcase returns nil if it doesn't have anything to upcase...
//F