Lingkarkan melalui Java Treeset

for (Integer value : ts)
{
    System.out.print(value);
}
Unsightly Unicorn