What is empty character literal in Java?

An empty char value does not belong to any char , so Java gives a compile-time error. To create an empty char, we either can assign it a null value \0 or default Unicode value \u0000 . The \u0000 is a default value for char used by the Java compiler at the time of object creation.

Sizin İçin Seçtik  How do you replace a character in a string with empty?

Leave a Reply

Your email address will not be published. Required fields are marked *