Multiple Choice Question

Quiz Guidelines

 

QID: 
18
Tags: 
Validated against: 
java8
Question: 

Which of these array declarations and initializations are NOT legal?

 

Select 2 options

A. int[ ] i[ ] = { { 1, 2 }, { 3 }, { }, { 4, 5, 6 } } ;

B. int i[ ] = new int[2] {1, 2} ;

C. int i[ ][ ] = new int[ ][ ] { {1, 2, 3}, {4, 5, 6} } ;

D. int i[ ][ ] = { { 1, 2 }, new int[ 2 ] } ;

E. int i[4] = { 1, 2, 3, 4 } ;

Q&A Set: