A small example about how Ruby is evolving
A small example about how #Ruby is evolving.
I took a code sample from a feature request from 2011 and wrote it using features that will be available in Ruby 3.4
In case you are wondering, _1
is called a numbered block parameter,
and in this case, it is a shorthand syntax for the first parameter in
that block.
You can play with it
block param already using https://ruby-next.github.io