import Sav.Processor.*;
class Group {
public static void main(String args[]) throws Exception {
    /* Grouping */
    Association a = new Association();
    a.set("Java").set("Java object").set("Java tool").set("C++");
    //a = {Java, Java object, Java tool, C++}
    Concept cWord = new Concept("Java");
    /** The line extracts a subassociation of concepts defined by the "Java " */
    a.see("Java ");//a = {Java object, Java tool}
    a.see("");     //a = {Java, Java object, Java tool, C++}
    a.see(cWord);  //a = {Java, Java object, Java tool}
    String s = cWord.toString();
    System.out.println(s + " GROUP" + '\n');
    Concept c = a.getFirst();
    while (c != null) {
        System.out.println(c);
        c = a.getNext();
    }
    /* Ordering */
    System.out.println("\nORDER");
    a = new Association();
    a.set("9").set("10").set("#10").set("#9");//a = {10, 9, #9, #10}
    for (c = a.getFirst(); c != null; c = a.getNext()) {
        System.out.print(c + " ");
    }
    System.out.println();
    a.see(PN.NUMBER); //a = {#9, #10}
    c = a.getFirst(); //c = #9, because 9 numeric < 10 numeric
    System.out.println(c);
    a.see(PN.ARITHMETICAL); //a = {10, 9}
    c = a.getFirst(); //c = 10, because code of the '1' < code of the '9'
    System.out.println(c);
}//main()
}//class Group