Q.- Given the code fragment:
List<String> lst = Arrays.asList ("EN", "FR",”CH”,”JP”);
Iterator itr = lst.iterator( );
while (itr.hasNext()) {
String = itr.next( );
if (e = "CH") {
break;
}
System.out.print (e + " ");
}
What is the result?
A) EN FR
B) EN FR JP
C) CH
D) EN FR CH
⧪ please give your answer in a comment section.
List<String>
3 Comments
C
ReplyDeletea
ReplyDeleteA
ReplyDelete