Convert Binary to Float (and back)

I’ve hacked together some rather ugly code to convert a Binary to a
Float but was hoping there is a more elegant way using perhaps pack and
unpack

Nebiru wrote:

I’ve hacked together some rather ugly code to convert a Binary to a
Float but was hoping there is a more elegant way using perhaps pack and
unpack

Look at

ri Array#pack

And play around with those options.

T.