// Collection of code snippets by Arne Vajhøj 
// (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) 
public class MStr {
    private static void test1() {
        String s1 = "ABC";
        String s2 = "ABC";
        System.out.println(s1==s2);
        System.out.println(s1=="ABC");
    }
    private static void test2() {
        String s1 = new String("ABC");
        String s2 = new String("ABC");
        System.out.println(s1==s2);
        System.out.println(s1=="ABC");
    }
    public static void main(String[] args) {
        test1();
        test2();
    }
}
