PHP Functions What will be the output of the following PHP code?$op2 = "blabla";function foo($op1) {echo $op1;echo $op2;}foo("hello"); helloblablablabla hello helloblabla error helloblablablabla hello helloblabla error ANSWER DOWNLOAD EXAMIANS APP
PHP Functions It is always necessary to use parentheses with the print function. False True False True ANSWER DOWNLOAD EXAMIANS APP
PHP Functions What will be the output of the following PHP code ?function calc($num1, $num2){$total = $num1 * $num2;return $total; }$result = calc(42, 0);echo $result; Error 42 0 84 Error 42 0 84 ANSWER DOWNLOAD EXAMIANS APP
PHP Functions Which one of the following is the right way of defining a function in PHP? functionName(parameters) { function body } data type functionName(parameters) { function body } function { function body } function fumctionName(parameters) { function body } functionName(parameters) { function body } data type functionName(parameters) { function body } function { function body } function fumctionName(parameters) { function body } ANSWER DOWNLOAD EXAMIANS APP
PHP Functions What will be the output of the following PHP code ?function email(){$email = ’contact@examians.com’;$new = strstr($email, ‘@');echo $new;}email(); contact contact@examians.com examians.com @examians.com contact contact@examians.com examians.com @examians.com ANSWER DOWNLOAD EXAMIANS APP
PHP Functions What will be the output of the following PHP code?function onespan>() {define("const","I am awesome!");echo constant("const");}one(); const, I am awesome!! I am awesome!! const “const”,”I am awesome!” const, I am awesome!! I am awesome!! const “const”,”I am awesome!” ANSWER DOWNLOAD EXAMIANS APP