0

I have seen code which uses a double not (!!) for checking a pointer.But I am not finding an advantage of using !! in the condition check.Can some one shed some light on the purpose and advantage of using it.

int *Ptr;
/* ... */
if(!!Ptr)
{
  /* ... */
}
Hcorg
  • 11,598
  • 3
  • 31
  • 36
achoora
  • 1,270
  • 1
  • 16
  • 32

0 Answers0