Example | java.lang package | Character class | charCount() method
java.lang.Character.charCount() |
Signature:
public static int charCount(int codePoint)
Description:
Determines the number of char values needed to represent the specified character (Unicode code point). If the specified character is equal to or greater than 0x10000, then the method returns 2. Otherwise, the method returns 1.
Parameter:
Since:
Example:
- If codePoint is less than 0X10000 or 65536. It returns 1.
- If codePoint is equal to 0X10000 or 65536. It returns 2.
- If codePoint is greater than 0X10000 or 65536. It returns 2.
References:
Thank you friends, I hope you have clearly understood this method. If you have any doubt, suggestion or query please feel free to comment below. You can also discuss it in our forum.
Example | java.lang package | Character class | charCount() method
Reviewed by Rohit Agarwal
on
8/28/2017
Rating:
No comments:
Please provide your valuable comments. If you have any suggestion please share with me I will work on it and if you have any question or doubt please ask, don't hesitate. I am your friend, i will clarify all your doubts.