Divisibility by 10^k-1, 10^k+1 (2nd explanation besides Vivian Loh's is mine)
By converting a decimal number to base 20 we can easily check divisibility by 21 (and therefore 7) and 19. The conversion is achieved by subtracting multiples of powers of 2 in descending order (64, 32, 16, 8, 4, 2 etc.) from the decimal number starting at the beginning of the number.
Example:
Take the decimal number 1453. As there is no point in subtracting a multiple of 8 from 1 we take the first two digits, 14 and subtract the greatest multiple of 4 less than 14, which is 12. We are left with 253. The next power of 2 in descending order after 4 is 2. The greatest multiple of 2 after 25 is 24. Notice that vigesimal (base 20) numbers can have two decimal digits, so we get 12 as the next base 20 “digit". We are left with 1 which carries over to 3 as the vigesimal “digit" 13. Thus the vigesimal number we have found is (in two-decimal-digit notation) 03 12 13. 13 - 12 + 3 = 4, so 1453 is 4 (mod 7) which is correct, given that 1449 is divisible by 7.
Another example:
Take the number 187607. Counting from the end, we have the powers of two 1, 2, 4, 8, 16 for five digits. It makes no sense to try divide the first digit, 1, by 32. Instead we divide 18 by 16 and get a quotient of 1 and a remainder of 2. We divide 27 by 8 and get a quotient of 3 and a remainder of 3, We are left with 36 and then a zero. We divide 36 by a and get a quotient of 9 and no remainder. We are left with 2 decimal digits and two descending powers of 2 (2 and 1). As we should always leave the last decimal digit unaltered in conversion from decimal to vigesimal we complete the vigesimal number with 0 as a multiple of 2 and 7 as a multiple of 1. Therefore, collecting the quotients, the vigesimal number we found is 01 03 09 00 07. 7 - 0 + 9 - 3 + 1 = 14, so the decimal 187607 is divisible by 7. 7 + 0 + 9 + 3 + 1 = 20, therefore 187607 leaves a remainder of 1 when divided by 19.