试题详情
多项选择题 1. import java.util.*;  2. public class Test {  3. public static void main(String[] args) {  4. List strings = new ArrayList();  5. // insert code here  6. }  7. }  Which four, inserted at line 5, will allow compilation to succeed?()

A、 String s = strings.get(0);

B、 Iterator i1 = strings.iterator();

C、 String[] array1 = strings.toArray();

D、 Iterator i2 = strings.iterator();

E、 String[] array2 = strings.toArray(new String[1]);

F、 Iterator i3 = strings.iterator();

  • A,B,D,E
  • 关注下方微信公众号,在线模考后查看

热门试题