Discussion Forum : Php Control Structures (loop)
Question - What will be the output of the following PHP code ?$a = array("hi", "hello", "bye");for (;count($a) < 5;) {if (count($a) == 3)print $a;}
Options:
A .  (“hi”,”hello”,”bye”)(“hi”,”hello”,”bye”)(“hi”,”hello”,”bye”)(“hi”,”hello”,”bye”)…infinitely
B .  ArrayArrayArrayArrayArrayArray….infinitely
C .  hihellobyehihellobyehihellobyehihellobyehihellobyehihellobye…..infinitely
D .  no output
Answer: Option B

Submit Your Solution Below and Earn Points !
Next Question
Submit Your Solution hear:

Your email address will not be published. Required fields are marked *