What will be the output of the following PHP code? [code] <?php function calc($price, $tax="") { $total = $price + ($price *

What will be the output of the following PHP code?
Code:
    <?php
    function calc($price, $tax="")
    {
        $total = $price + ($price * $tax);
        echo "$total"; 
    }
    calc(42);    
    ?>
A. Error
B. 0
C. 42
D. 84
 

Tìm kiếm

Back
Top