// Collection of code snippets by Arne Vajhøj 
// (from articles on eksperten.dk / vajhoej.dk written sometime between 2004 and now) 
public class J {
    public static void main(String[] args) throws Exception {
        Gr gr = new Gr();
        int v1 = 123;
        int v2 = 456;
        int v3 = gr.add(v1, v2);
        System.out.printf("%d + %d = %d\n", v1, v2, v3);
        String s1 = "ABC";
        String s2 = "DEF";
        String s3 = gr.conc(s1, s2);
        System.out.printf("%s + %s = %s\n", s1, s2, s3);
        GrData o = new GrData();
        o.setIv(123);
        o.setSv("ABC");
        System.out.printf("iv=%d sv=%s\n", o.getIv(), o.getSv());
        GrData o2 = gr.modify(o);
        System.out.printf("iv=%d sv=%s\n", o2.getIv(), o2.getSv());
    }
}
