Take a look at the following code snippet in Java.
final public class Main { public static void main(String[] args) { Locale.setDefault(new Locale("lt")); String str = "\u00cc";
It displays the following output.
Before transforming the case Ì and length 1
Lowercase is i ̇̀ and length is 3
In the first statement, System.out.println() result is accurate. However, the second expression displays the length 3 , which should actually be 1 . I do not understand why?
source share