Help for this page

Select Code to Download


  1. or download this
        $ perl -e 'printf "%2.4g\n", 23.05'
        23.05
        $ perl -e 'printf "%2.4g\n", 23.00'
        23
    
  2. or download this
        g    The  double  argument  is converted in style f or e
             (or E for G conversions).  
    ...
             Trailing zeros are removed from the fractional part
             of  the result;
             ...