In Go, error values are commonly checked against _______ to determine if they are non-nil.

  • err
  • error
  • nil
  • panic
In Go, error values are commonly checked against the error interface to determine if they are non-nil. The error interface is the built-in interface type in Go that represents an error condition. It is defined as type error interface { Error() string }, which means any type that implements a method Error() string satisfies the error interface.
Add your answer
Loading...

Leave a comment

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