In PHP, if a function is supposed to return a value, the _______ statement is used.

  • print
  • echo
  • return
  • output
The correct option is: "return." In PHP, the return statement is used within a function to specify the value that should be returned as the result of the function. The return statement can also be used to exit the function early if necessary. Learn more: https://www.php.net/manual/en/functions.returning-values.php
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *