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