Examveda
Examveda

What will be the output of the following PHP code ?
<?php
for ($x = 1; $x < 10; $x++)
    for ($y = 1; $y < 5; $y++)
        print "Hello";
?>

A. Hello….36 times

B. Hello….45 times

C. Hello….50 times

D. Hello….40 times

Answer: Option A

Solution(By Examveda Team)

9*4 times is printed.

This Question Belongs to PHP >> Control Structures(Loop In PHP)

Join The Discussion

Related Questions on Control Structures(Loop in PHP)