The proof of this magic trick is relatively easy, check it out.
So ab = 10*a + b
Now subtract a + b from ab which gives you 10a + b Ð ( a + b) = 9a
By the divisibility rule for 9, the sum of the digits will be a multiple of 9