Multiple choice

Which of the following is/are the valid array initialization(s) in php language?

  1. $fruit= array(Apple, Mango, Banana);
  2. var fruit=new array(Apple, Mango, Banana);

  3. $rate=array(Apple=>50,Mango=>20,Banana=>40);
  4. $fruit=array ( array(Apple,50,60), array(Mango,20,25), array(Banana,40,45) );
  5. (1), (3), and (4) are valid.

Reveal answer Fill a bubble to check yourself
E Correct answer
Explanation

Yes, these three are the true initializations of the array in php.