PHP Functions What will be the output of the following PHP code?function calc($price, $tax="") {$total = $price + ($price * $tax);echo "$total";}calc(42); 84 0 42 Error 84 0 42 Error ANSWER DOWNLOAD EXAMIANS APP
PHP Functions What will be the output of the following PHP code?echo ord ("hi"); 104 106 103 209 104 106 103 209 ANSWER DOWNLOAD EXAMIANS APP
PHP Functions Which one of the following is the right way of defining a function in PHP? data type functionName(parameters) { function body } functionName(parameters) { function body } function fumctionName(parameters) { function body } function { function body } data type functionName(parameters) { function body } functionName(parameters) { function body } function fumctionName(parameters) { function body } function { function body } ANSWER DOWNLOAD EXAMIANS APP
PHP Functions The below statement will return.$Var = substr(""abcdef"", -4, 1); returns "f" returns "c" returns "cd" returns "d" returns "f" returns "c" returns "cd" returns "d" ANSWER DOWNLOAD EXAMIANS APP
PHP Functions What will be the output of the following PHP code ?function start($string){if ($string < 45)return 20;elsereturn 40;}$t = start(90);if ($t < 20){echo "Have a good day!";}else{echo "Have a good night!";} Have a good day! None of the mentioned Have a good night! ERROR Have a good day! None of the mentioned Have a good night! ERROR ANSWER DOWNLOAD EXAMIANS APP
PHP Functions What will be the output of the following PHP code?function a() {function b() {echo 'I am b';}echo 'I am a';}a();a(); I am b Error I am bI am a I am a Error I am b Error I am bI am a I am a Error ANSWER DOWNLOAD EXAMIANS APP