q = new LinkedList();
QueueTester tester = new QueueTester(); try { tester.testFIFO(System.out); } catch (IOException e) { e.printStackTrace(); }
q.add("First"); q.add("Second"); q.add("Third"); Object o; while ((o = q.poll()) != null) { out.println(o); }