DEV Community

loading...

Discussion on: Bitwise Operations in C/C++

Collapse
abellgithub profile image
Andrew Bell

Well, you use them when you want to know the values of bits. Tons of systems encode information on as few bits as possible to save space. Compression algorithms map character strings and numeric values to packed bit streams. Transmission protocols store flags and sometimes node addresses as some number of bits that aren't byte multiples. It's ubiquitous in embedded systems.