Java BigDecimal intValue() methodThe hashCode() method of java BigDecimal class is used to Convert a BigDecimal to an int type value. Note: This conversion can lose information about the overall magnitude and precision of this BigDecimal value as well as return a result with the opposite sign.Syntax:Parameter:No Exception:No Returns:It returns int value of BigDecimal. Example 1Test it NowOutput: Returned int value is = 3545 Example 2Test it NowOutput: Returned int value is = -36755 Example 3Test it NowOutput: Returned int value is = -1011088953 Example 4Test it NowOutput: Returned int value is = 3283878 Next TopicJava BigDecimal |
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