The following table shows the powers of two as a quick reference for people. I originally saw it in the book Cracking the Coding Interview and figured it should stay here.
Power of 2 | Exact Value | Approximate Value | Approx Bytes |
---|---|---|---|
7 | 128 | ||
8 | 256 | ||
10 | 1024 | 1 Thousand | 1K |
16 | 65,536 | 64K | |
20 | 1,048,576 | 1 Million | 1MB |
30 | 1,073,741,824 | 1 Billion | 1GB |
32 | 4,294,967,296 | 4GB | |
40 | 1,099,511,627,776 | 1 Trillion | 1TB |