Can you do == in Java?

In Java Strings, the == operator is used to check the reference of both the string objects and equals() method used to check the value equality of both strings. When we assign a string value to the string variable, the JVM will check if the string with the equal value already present in the string pool or not.

Sizin İçin Seçtik  What are the different type of token?

Leave a Reply

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