Display only 2 digits after decimal
3 answers
It works - means that the digit is printed only if it is relevant (see documentation ). Try to use
bill[p][l][0] = new DecimalFormat("##.00").format(Double.parseDouble(i2[m][0]));
+5
source to share