0

Decimal format issues:

DecimalFormat format = new DecimalFormat("###.#####");
Double d = new Double(122433423424.59696D);
System.out.println(format.format(d));

Output:

122433423424.59695

but need exact value like:

122433423424.59696

1 Answers1

1

Use string constructor of BigDecimal, ie

new BigDecimal("12243342342.59696")
ThomasEdwin
  • 2,035
  • 1
  • 24
  • 36