Author Topic: What is ~0?  (Read 2200 times)

Farabi

  • Member
  • ****
  • Posts: 970
  • Neuroscience Fans
What is ~0?
« on: July 30, 2012, 07:04:35 PM »
What is "~0" mean on C++ programming? Is it mean reverse all of the zero bit? ~0=0FFFFFFFFh?
http://farabidatacenter.url.ph/MySoftware/
My 3D Game Engine Demo.

Contact me at Whatsapp: 6283818314165

qWord

  • Member
  • *****
  • Posts: 1473
  • The base type of a type is the type itself
    • SmplMath macros
Re: What is ~0?
« Reply #1 on: July 30, 2012, 08:04:08 PM »
yes
MREAL macros - when you need floating point arithmetic while assembling!

Ghandi

  • Guest
Re: What is ~0?
« Reply #2 on: July 31, 2012, 05:12:31 PM »
The '~' operator is a bitwise NOT, otherwise known as "one's compliment":

http://www.cprogramming.com/tutorial/bitwise_operators.html

HR,
Ghandi