This story on HackerNoon has a decentralized backup on Sia.
Transaction ID: DB8eAG3kwp5JtT3Eosx7ZlpVAwG8CkXgyaZVNTKJz74
Cover

How to Manipulate Bits in C and C++

Written by @botman1001 | Published on 2019/12/4

TL;DR
In C++ programming language int data type is 16-bit, 32-bit and 64-bit type. In programming, an n bit integer is stored as a binary number that consists of n bits. In a signed representation, first bit represents the sign of a number (0 for positive and 1 for negative), and remaining n-1 bits contains the magnitude of the number. In an unsigned representation, the next number after the first bit is even and ifthenis odd. We can use & operator to check if a number is even or odd.

[story continues]


Written by
@botman1001
Technical Writer on HackerNoon.

Topics and
tags
cpp|c|bitmasking|bit-manipulation|manipulate-bits|software-development|programming|c++|hackernoon-es
This story on HackerNoon has a decentralized backup on Sia.
Transaction ID: DB8eAG3kwp5JtT3Eosx7ZlpVAwG8CkXgyaZVNTKJz74