Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The best is the 9's table, how all the digits add up to 9. My mom's an elementary teacher and there's always a few third graders who figure that out on their own and love it.


Additionally 9 * n = [n-1, 10-n] for n = 2-11; where n-1 is the digit in the 10's place and 10-n in the single place. This just an aesthetic curiosity. I know the pattern continues for larger n I've just never bothered to generalize it. Also never compared it to other bases.


It's not an aesthetic curiosity at all! 10 is equal to 1 mod 9... So suppose X is written in base 10 (a0 * 10^0 + a1 * 10^1 + a2 * 10^3 +...) and you want to find X mod 9. Then all of the 10^k's are just 1 (mod 9), so you just get the sum of the digits.

So if X is divisible by 9, then the sum of the digits (mod 9) is zero.

Same works for 3 (x is div by 3 iff the sum of the digits id divisible by 3). And 11 gets an /alternating/ sum of the digits, since 10 is -1 mod 11...


> [n-1, 10-n] for n = 2-11

I think the usual 10 * n - n makes more sense and is much easier to remember.


I was legit angry that I didn't learn about the divisibility checks for 3 and 11 until college...




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: