not equal to in java

not equal to in java

equal to (==)
not equal to (!=)

/**
 * @author lautturi.com 
 * Java example: not equal to
 */

import java.util.*;

public class Lautturi {
	public static void main(String args[]) {
		int i = 5;
		if (i != 10) {
			System.out.println("the i is not equal to 10");
		}
		String str = "hello";
		if(!str.equals("Hello")) {
			System.out.println("the string is not equal to Hello");
		}
	}
}
Sour‮w:ec‬ww.lautturi.com

output:

the i is not equal to 10
the string is not equal to Hello
Created Time:2017-10-05 12:52:00  Author:lautturi