code obfuscation

I admit I was tricked:

 

import java.util.ArrayList;
public class ListProvider {
  public static <ArrayList> ArrayList getList(ArrayList ar) {
    return ar;
  }
  public static void main(String[] args) {
      getList("I am a list");
  }
}

This code compiles and runs of course.

shlomo 22/06/2009 - 21:53
Syndicate content