What Will Be The Output Of The Following Php Codep Pre Langphp #565
What will be the output of the following PHP code?</p> <pre><code class="language-php" line="1"> <?php $a = 100; if ($a > 10) printf("M.S. Dhoni"); else if ($a > 20) printf("M.E.K Hussey"); else if($a > 30) printf("A.B. de villiers"); ?> </code></pre>
This multiple choice question (MCQ) is related to the book/course gs gs107 PHP: Hypertext Preprocessor. It can also be found in gs gs107 Looping Statements - PHP If-Else-If - Quiz No.3.
What will be the output of the following PHP code?
<?php $a = 100; if ($a > 10) printf("M.S. Dhoni"); else if ($a > 20) printf("M.E.K Hussey"); else if($a > 30) printf("A.B. de villiers"); ?>
M.S.Dhoni
M.E.K.Hussey
M.S.Dhoni M.E.K.Hussey A.B.de villiers
No output