ExamVeda
Login
Home
Control Structures(Loop in PHP)
?

What will be the output of the following PHP code ?
<?php
$a = "";
if ($a) 
    print "all";
if 
else 
    print "some";
?>

Answer & Solution
Correct Answer: Option B
Empty string is evaluated to 0.
Examveda
Question posted by Examveda
Community

Join the Discussion

No comments yet Be the first to discuss this question.