Possible Duplicate:
Can I use a binary literal in C or C++?
In C I can write
uint32_t a = 0x40022000;
using hex. Can I do something similar by entering binary digits?
You can't do that with standard C, but some compilers such as gcc supports an extension that allows you to write something like
uint32_t a = 0b11010101110101;
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With