Advertisement
Rukes

Untitled

Dec 30th, 2018
132
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.     public static String getDoubleFormat(double input) {
  2.         String format =  String.format("%.2f", input);
  3.         if (format.endsWith(".00")){
  4.             format = format.substring(0, format.length() - 3);
  5.         }
  6.         return format;
  7.     }
Advertisement
RAW Paste Data Copied
Advertisement