Java BigDecimal intValueExact() MethodLast Updated : 17 Mar 2025 The intValueExact() method of java BigDecimal class is used to Convert a BigDecimal to an int type as well as this method also check for the lost information. Syntax:Parameter:No Exception:If this has a non-zero fractional part, or will not fit in an int, then it throws an ArithmeticException. Returns:It returns int value from BigDecimal. Example 1Output: Returned Exact Integer Value of 17674137 is = 17674137 Example 2Output: Returned Exact Integer Value of -623341 is = -623341 Example 3Output: ArithmeticException Example 4Output: ArithmeticException Next TopicJava BigDecimal |
We request you to subscribe our newsletter for upcoming updates.

We deliver comprehensive tutorials, interview question-answers, MCQs, study materials on leading programming languages and web technologies like Data Science, MEAN/MERN full stack development, Python, Java, C++, C, HTML, React, Angular, PHP and much more to support your learning and career growth.
G-13, 2nd Floor, Sec-3, Noida, UP, 201301, India