The small java puzzle

Given the following code, what will be the outcome?

import java.util.Set;
import java.util.TreeSet;

public class A {
    public static void main(String[] args) {
      Set sets = new TreeSet();
      sets.add("1");
      sets.add("3");
      sets.add(new Integer(2));
      System.out.println(sets.isEmpty());
    }
}

This entry was posted on Monday, August 20th, 2007 at 22:37 and is filed under development, java. You can follow any responses to this entry through the RSS 2.0 feed. Responses are currently closed, but you can trackback from your own site.

Comments are closed.