What will be the result of the expression !!true?

  • Compilation Error
  • FALSE
  • Runtime Error
  • TRUE
The expression !!true is a double negation of the boolean value true. It will result in true. The first ! operator negates true to false, and the second ! operator negates false back to true. This is a common way to ensure a boolean value is truly true.
Add your answer
Loading...

Leave a comment

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