News for hackers. Stuff that matters.
Re:Divisibility by 7 by spicyj on Saturday October 30, 2010 @11:40PM (#1852425)
I do math contests competitively, so I remember these things. Here are some rules:

Divisibility by 2: Last digit is divisible by 2 (0, 2, 4, 6, or 8).

Divisibility by 3: Sum of digits is divisible by 3. (You can repeatedly sum the digits until the sum is small enough to manage easily.)

Divisibility by 4: Last two digits are divisible by 4 (00, 04, 08, 12, ...). If you don't know your multiples of four, you can divide the two digits by 2 and then see if it's even.

Divisibility by 5: Last digit is divisible by 5 (0 or 5).

Divisibility by 6: Divisible by 2 and by 3. (Works similarly for all composite numbers, of course. Like 10, 14, 15, etc. Make sure the factors you're checking are relatively prime (share no common factors), or it won't work. For example, divisibility by 2 and 6 does not imply divisibility by 12.)

Divisibility by 8: Last three digits are divisible by 8 (000, 008, 016, ...). Probably faster to divide the last three by 2 at least once then check divisibility by 4.

Divisibility by 9: Sum of digits is divisible by 9. (You can repeatedly sum the digits until the sum is small enough to manage easily.)

Divisibility by 11: Alternating sum of digits is divisible by 11. (Almost always turns out to be -11, 0, or 11. Example: 66374. 6 - 6 + 3 - 7 + 4 = 0, so 66374 is divisible by 11.)

Re:Divisibility by 7 by omaranto on Sunday October 31, 2010 @02:29AM (#1852649)
Seeing this list of silly things one might find useful in high school math contests made me nostalgic for those days...
Re:Divisibility by 7 by jacquesm on Sunday October 31, 2010 @06:22AM (#1853003)
They're not that silly actually.

Division is the most 'complicated' of the arithmetic operations and if you rely on doing sums in your head frequently then knowing such shortcuts can speed up the calculations considerably.

It also helps in checking results of other calculations.

Re:Divisibility by 7 by Panoramix on Sunday October 31, 2010 @08:56AM (#1853182)
I find this kind of things extremely handy in my everyday job. Especially in meetings, since often you are forced to do mental arithmetic to estimate the magnitude of a parameter, etc. Abusing the calculator can put your brain in poor shape, just like muscles!
Re:Divisibility by 7 by omaranto on Wednesday November 03, 2010 @09:54AM (#1864761)
Seriously? You use divisibility tests to make estimations? I hope nothing much is riding on those estimates...
Re:Divisibility by 7 by xyzzyz on Sunday October 31, 2010 @07:37AM (#1853091)
Silly? Some people do math for a living.
Re:Divisibility by 7 by omaranto on Wednesday November 03, 2010 @09:52AM (#1864755)
I do math for a living. Needing to now whether a small integer is divisible by 7 rarely comes up. And when it dos we tend to let dumb machines handle the easy stuff, leaving humans free to think.
Re:Divisibility by 7 by alextgordon on Sunday October 31, 2010 @08:22AM (#1853146)
Those people don't get paid by the hour, so they use a calculator :)
Re:Divisibility by 7 by kijinbear on Sunday October 31, 2010 @01:54AM (#1852586)
> relatively prime

Do primes come in degrees these days?

Re:Divisibility by 7 by sid0 on Sunday October 31, 2010 @02:02AM (#1852602)
I'm not sure if this is humour or not, but "relatively prime" or "coprime" means that the two numbers have GCD 1.