Skip to content

Instantly share code, notes, and snippets.

@cpegel
Created October 20, 2019 10:03
Show Gist options
  • Save cpegel/9bbcea1254f9f535a5ed38f8f1eef0e7 to your computer and use it in GitHub Desktop.
Save cpegel/9bbcea1254f9f535a5ed38f8f1eef0e7 to your computer and use it in GitHub Desktop.
rio@morty ~> cat foo.java
public class foo {
public static void main(String[] args) {
String bar = new String("qux");
String baz = new String("qux");
if(bar == baz) {
System.out.println(bar + " == " + baz);
}
System.out.println(bar + " != " + baz);
}
}
rio@morty ~> java foo
qux != qux
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment