165
Java Byte longValue() method
The longValue() method of Java Byte class returns a long value for this Byte after a widening primitive conversion.
Syntax:
Parameters:
NA
Specified by
This method is specified by longValue in class Number
Return Value
This method returns the numeric value of this object after conversion to type long.
Example 1
Output:
Long value : 98 Long value : 102
Example 2
Output:
Maximum number between 26 and 45 : 45 Minimum number between 26 and 45 : 26
Example 3
Output:
Sum : 20 + (-9) : 11
Next TopicJava Byte