For those outside the Rails community who have no idea what I’m on about, some people got a bit upset about Rails 2.2 defining Array#second
up to Array#tenth
, so for example you can call foo.fifth
instead of foo[4]
(you can already call foo.first
instead of foo[0]
). One of the last changes to be committed before 2.2 was released was to slim the list down to just second, third, fourth and fifth, but adding Array#forty_two
(the ultimate answer) instead.
Categories
One reply on “My (very!) small part in the Array#forty_two controversy”
Good catch there!
However, this sort of syntactic sugar makes me shudder…