Home » PHP » PHP Functions » Question
  1. What will be the output of the following PHP code?
    <?php
    function Add($n1, $n2)
    {
    $total = $n1 + $n2;
    echo chr($total);
    }
    $var = "Add";
    $var(14, 41);
    ?>
    1. 7
    2. 41
    3. 14
    4. 55
    5. None of these
Correct Option: A

It is possible to call a function using a variable which stores the function name also the chr() function returns a character from the specified ASCII value.



Your comments will be displayed only after manual approval.