List<String> list = new ArrayList<String>();
// Get String at index 2 in list.
int index = 2;
String s = list.get(index);
// get returns an Object — see api.
// So if not using generics you will need to cast the
// value returned by/from the get method to the
// type you put into the list.
List list = new ArrayList();
int index = 2;
String s = (String)list.get(index);