from Alvinalexander11 months agoDeciamalFormat dfZero = new DecimalFormat("0.00");Alvinalexanderhttps://alvinalexander.com/java/how-round-double-float-two-decimal-places-format-output/String formattedNumber = String.format("%.2f", number);Alvinalexanderhttps://alvinalexander.com/java/how-round-double-float-two-decimal-places-format-output/ Read at Alvinalexander #java #double #float #decimalformat #precision-loss Collection [| ... ]