private void printTwoLists(List<String> list1, List<String> list2) {
Iterator<String> iterator1 = list1.iterator();
Iterator<String> iterator2 = list2.iterator();
while (iterator1.hasNext() && iterator2.hasNext()) {
System.out.println(
"iterator1.next() + \",\" + iterator2.next() = "
+ iterator1.next()
+ ","
+ iterator2.next());
}
if (iterator1.hasNext()) {
System.out.println("iterator1.next() = " + iterator1.next());
}
else if (iterator2.hasNext()) {
System.out.println("iterator2.next() = " + iterator2.next());
}
}