[1, 2, 3].map(&method(:random))
Pretty sure the & is superfluous, #method should return a callable :)
@richoh Nope. method returns Method class, and we need to pass block. afaik ampersand operator is the only way to convert proc / lambda / method to block.
Ah, my bad. Thanks for clearing that up.
For the unenlightened...like me :-. What is the underlying intent in the above example?
Any hints appreciated.