String is one of the most fundamental data structure. It is versatile and useful for many cases. This is why Strings are used in many cases instead of using more restrictive data structure. But sometimes we need to Compare two or more Strings for specific programming needs. Below are som examples on how we can compare Strings in Java.