Math Fundamentals18 sections · 814 units
Open in Course

What Are Bits?

Binary foundation

A bit is a single binary digit: either 0 or 1. It's the smallest unit of information a computer can store.

When you group bits together, you get binary numbers. For example, the binary number 10111011 represents (1×23)+(0×22)+(1×21)+(1×20)=8+0+2+1=11(1 \times 2^3) + (0 \times 2^2) + (1 \times 2^1) + (1 \times 2^0) = 8 + 0 + 2 + 1 = 11 in decimal.

Computers typically work with groups of 32 or 64 bits to represent integers. In this section, I'll focus on how you can manipulate individual bits within these numbers to solve problems.