class Vector<T> {
  private T e;
  void set( int i, T e ){ this.e = e; }
  T get(int i){ return e; }
}

class G1 {
  public static void main( String[] args ){
     Vector<String> v = new Vector<String>();      // homogeneity
     v.set(0,"Cool stuff");
     String s = v.get(0);

     Vector<Thread> w = new Vector<Thread>();
     w.set(0,new Thread());
     Thread t = w.get(0);

     // v.set(0,t); w.set(0,"Bad luck");
     // t = v.get(0); s = w.get(0);
  }
}

/*
class VectorOfString {                     // this is NOT what happens, but...
  private String e;
  void set( int i, String e ){ this.e = e; }
  String get(int i){ return e; }
}

class VectorOfThread {
  private Thread e;
  void set( int i, Thread e ){ this.e = e; }
  Thread get(int i){ return e; }
}
*/