Multiple Choice
What is the output of the following statements? ArrayList<String> names = new ArrayList<String>() ;
Names.add("Bob") ;
Names.add(0, "Ann") ;
Names.remove(1) ;
Names.add("Cal") ;
Names.set(2, "Tony") ;
For (String s : names)
{
System.out.print(s + ", ") ;
}
A) Cal, Bob, Ann
B) Ann, Bob
C) Ann, Cal, Tony
D) Array list bound error
Correct Answer:

Verified
Correct Answer:
Verified
Q41: Suppose you wish to process an array
Q79: Which statements about array algorithms are true?<br>I.
Q80: Consider the following line of code:<br>Int[] somearray
Q81: Which statement is true about the code
Q83: Which one of the following is the
Q85: Consider the following code snippet:<br>Int[][] arr =<br>{<br>{
Q86: Consider the following code snippet:<br>Int[][] numarray =<br>{<br>{
Q87: Assume the following variable has been declared
Q88: Which one of the following statements is
Q102: Java 7 introduced enhanced syntax for declaring