N
Q. What will be the output of the following PHP code?
<?php $user = array("Ats ", "Ajit ", "Rahul ", "Aju "); for ($str=0; $str < count($user); $str++) { if ($user[$str] == "Rahul ") continue; printf ($user[$str]); } ?>
When the mentioned for loop executes, it will start printing all the strings in the array. But when it sees that the if condition is true, it doesn't print the string and just skip the code below it and start with next value. So it will print "Ats Ajit Aju " only.
You must be Logged in to update hint/solution
Q. Object are created using _______ keyword?
Q. What is name of PHP "<=>" operator?
Q. What is the result of the following PHP code?
Q. --------is a method of accessing database data using object-oriented syntax instead of using SQL
Q. Which loop statement is used to loop through a block of code a specified number of times?
Q. What will be the output of the following PHP code ?
Q. What will be the output of the following PHP code ?
Q. What will be the output of the following PHP code?
Discusssion
Login to discuss.