ExamVeda
Login
Home
Control Structures(Loop in PHP)
?

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

Answer & Solution
Correct Answer: Option A
The value of a is evaluated to 1 as it has a value.
Examveda
Question posted by Examveda
Community

Join the Discussion

No comments yet Be the first to discuss this question.