How Binary Works
Binary is a base-2 number system using only 0 and 1. Each position represents a power of 2. Computers use binary because transistors have two states: on (1) and off (0).
101010₂ = 1×32 + 0×16 + 1×8 + 0×4 + 1×2 + 0×1 = 42₁₀
Frequently Asked Questions
How do I convert binary to decimal? Multiply each bit by its power of 2 (from right: 1, 2, 4, 8, 16...) and sum the results.
What are bitwise operations? AND (&), OR (|), and XOR (^) operate on individual bits. AND gives 1 only when both bits are 1. OR gives 1 when either bit is 1. XOR gives 1 when bits differ.