0 replies on 1 page.
Two array-related behaviors that took me off-guard this week.
Zsban Ambrus displayed this technique for ignoring a list assignment.
>> x, (*), z = [:x, :y, :z] => [:x, :y, :z] >> x => :x >> z => :z
And Christian Neukirchen showed the spooky split that the array constructor function does.
>> Array("foo\nbar") => ["foo\n", "bar"] >> $/ = ' '; Array( "i'm in your house" ) => ["i'm ", "in ", "your ", "house"]
Read: Principle Of List Surprise