java.lang.Double intValue()

Syntax:

public int intValue()

Java Code Example :

This java example source code demonstrates the use of intValue() method of Double class.

Some takeaways on the intValue method:

  • returns the value of this Double as an int after a narrowing primitive conversion.
  • specified by intValue in class Number

Sample Output :

Running the above example source code will give the following output

Suggested Reading List :

References :