I am unable to understand what all?
does. In the following code, the first two lines are the same. Why are the outputs different? Is it a bug or is it its default behaviour?
[false, false, true, true, true, true, false, false, true, true].all? # => false
[true, true, true, true, true, true, true, true, true, true].all? # => true
[0, 0, 1, 1, 1, 1, 0, 0, 1, 1].all? # => true