answersLogoWhite

0


Best Answer

Remember that strings are objects. You can use the String.equals method to determine equality, and use the ! (not) operator to test for inequality.

public static boolean notEquals(String str1, String str2) {

return !str1.equals(str2);

}

User Avatar

Wiki User

14y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How do you find out not equals string in java?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

How do you campaire Strings in java?

String class in Java has an 'equals' method that can be used to compare strings.


Where could someone find an example of Java string comparisons?

There are many sites to find examples of Java string comparisons. Java Revisited, Java Coffee Break, Alvin Alexander, Stack Overflow and Lee Point are a few to start with.


What are some ways in order to perform String comparison in Java?

String comparison in Java features four ways. These ways are String comparison using equals method, equalsIgnoreCase method, CompareTo method, and CompareToIgnoreCase method.


How can find the length of a string in java without using fun?

Use length() method. Example: "java".length();


Where can one find a tutorial on java string array?

There are many ways to find tutorials on Java string array. You can purchase the digital tutorials at a local computer store. There are also books you can check out at your local library.


Where can one find information on converting string to int java?

One can find information on converting string to int in Java by visiting the Stack Overflow website. This website is free to browse and has lots of information on this topic.


What are some example for string formatting in Java?

There are lots of examples of string formatting in Java. It can be difficult at times. Some of these examples are, but are not limited to; align, string, format, and JAVA.


Where could someone find a tutorial explaining java string format?

You can go to the library to find a book on java string format that will explain it. You can also go to different places like Oracle or Homeandlearn to get more information on the subject.


What does it mean to have a string split in java?

To have a string split in Java means that a string array, containing substrings (can be delimited by elements of a specified string or Unicode character array), is returned.


How to write A Java program to print number of digits in a given number?

One way to do this is to convert the number to a String, then use the corresponding String method to find out the length of the String.


What is equality in java?

equality is the status in Java wherein two objects are the same. the equals() method is used to check for equality. obj1.equals(obj2) would return a boolen value true or false signifying the equality. If the two objects are equal this would return a TRUE or else a FALSE ex: String str1 = "Hi"; String str2 = "Hiiii"; String str3 = "Hi"; System.out.println(str1.equals(str2)); System.out.println(str1.equals(str3)); The above code would print false true in the console.


In computer terms what does the phrase 'java string replace' mean?

When referring to computer terms, the phrase "java string replace" means that a string in the line of code that Java uses, is being replaced, or needs to be replaced.