A

Admin • 802.91K Points
Coach

Q. What will be the output of the following PHP code ?

Code:
<?php
$p = 5;
while($p = 20)
{
print "INDIA";
}
print "USA";
?>
  • (A) 5
  • (B) 20
  • (C) USA
  • (D) INDIA.....infinite time
  • Correct Answer - Option(D)
  • Views: 2
  • Filed under category PHP
  • Hashtags:

Explanation by: Admin
While condition always gives 1.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.