in reply to "Human" pretty-printer for data capacity
Thank you for sharing your code. There is a related module Number::Bytes::Human:
$ perl -l use strict; use warnings; use Number::Bytes::Human qw(format_bytes); print format_bytes(1E9, bs => 1000); print format_bytes(1E9, bs => 1024); __END__ 1.0G 954M
|
|---|