Java BigInteger doubleValue() methodThe doubleValue() method of Java BigInteger class is used to convert this BigInteger to a double.This conversion is similar to the narrowing primitive conversion from double to float. Narrowing Primitive Conversion:According to The Java Language Specification, It is defined as ifthisBigInteger has too great magnitude to represent as a double, it will be converted to Double.NEGATIVE_INFINITY or Double.POSITIVE_INFINITY as appropriate. SyntaxReturns:This method returns this BigInteger converted to a double. Note:ExampleTest it NowOutput: Result of doubleValue operation on 111 is111.0 Result of doubleValue operation on 22222222 is 2.2222222E7 Next TopicJava BigInteger |
We provides tutorials and interview questions of all technology like java tutorial, android, java frameworks
G-13, 2nd Floor, Sec-3, Noida, UP, 201301, India