Basic Datatypes
- Which class is a library of functions to perform arithmetic operations of BigInteger and BigDecimal?
-
View Hint View Answer Discuss in Forum
NA
Correct Option: B
MathContext class is a library of functions to perform arithmetic operations of BigInteger and BigDecimal.
- What is BigDecimal.ONE?
-
View Hint View Answer Discuss in Forum
NA
Correct Option: A
BigDecimal.ONE is a static variable of BigDecimal class with value 1 on scale 0.
- BigDecimal is a part of which package?
-
View Hint View Answer Discuss in Forum
NA
Correct Option: D
BigDecimal is a part of java.math. This package provides various classes for storing numbers and mathematical operations.
- Which of the following is not provided by BigDecimal?
-
View Hint View Answer Discuss in Forum
NA
Correct Option: D
toBigInteger() converts BigDecimal to a BigInteger.toBigIntegerExact() converts this BigDecimal to a BigInteger by checking for lost information.
- Which of the following is not provided by BigDecimal?
-
View Hint View Answer Discuss in Forum
NA
Correct Option: D
toBigInteger() converts BigDecimal to a BigInteger.toBigIntegerExact() converts this BigDecimal to a BigInteger by checking for lost information.