TreeSet ts = new TreeSet (new ComptexCompare());
ts.add(new Complex(1.2, 3.4));
ts. add (new Complex (-1.25, 33.4»;
ts.add(new Complex(1.23, -3.45));
ts.add(new Complex(16.2, 23.4));
Iterator it = ts.iterator();
while(it.hasNext()) , ((Complex)it.next()).pr();