why character takes two bytes in java
Why is a char two bytes?
Collapse
X
-
Tags: None
-
Please remember to provide a meaningful Title for any threads started (see the FAQ entry Use a Good Thread Title).
This helps to ensure that other members, and also the general public, will have a better chance of finding answers to any similar questions.
MODERATOR -
A char holds a Unicode value, which is two bytes:
Supplementary characters must be represented either as a surrogate pair within a char sequence, or as an integer, depending on the API they are used with.Comment
Comment