Java Bigdecimal

When working with financial, business applications, the programmer should know about the BigDecimal class

Java Bigdecimal

Java Bigdecimal

     

When working with financial, business applications, the programmer should know about the BigDecimal class and numeric formatting because you may get into problem when working with Java floating-point numbers. This situation arises because floating-point numbers can't be represented with all decimal numbers and complete accuracy. Java has BigDecimal class in "java.math" package to handle the situation. This class provides operations for arithmetic, scale manipulation, comparison, hashing, and format conversion and provides the user complete control over rounding. behavior.

Read more at:

http:/www.roseindia.net/java/beginners/AddTwoBigNumbers.shtml