Modified from Milo's Grisu2 implementation. 99.9% cases return shortest decimal format.
Attach a file by drag & drop or click to upload