Hacker News new | ask | show | jobs
by jonsen 5748 days ago
Memorize powers of 2 up to 9

  0   1   2   3    4    5    6    7    8    9
  1   2   4   8   16   32   64  128  256  512
and

  2^10 = 1K,   2^20 = 1M,   2^30 = 1G  etc.  
then split anything else

  ex. 2^23 = 2^20 * 2^3 =   8M
  ex. 2^37 = 2^30 * 2^7 = 128G
Edit: Also useful in reverse

  ex. 400K: 256K < 400K < 512K <=> 2^18 < 400K < 2^19
At least memorize 2^4 = 16 (hex) and 2^8 = 256 (byte), then do doubling or halving as necessary.