In Go, passing a pointer to a function allows _______ to be modified outside the function scope.

  • constants
  • structures
  • values
  • variables
Passing a pointer to a function in Go enables variables to be modified outside the function scope. This is because the function receives the memory address of the variable, allowing it to directly manipulate the data stored at that address.
Add your answer
Loading...

Leave a comment

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