[Solved] How do I check in JAVA if a string is not equal to? [closed]


Negate the returning value from string.equals(TestString):

!string.equals("ABC")

You better have a look at Logical Operators in Java

solved How do I check in JAVA if a string is not equal to? [closed]