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

Speed. The "trick" breaks down the problem so there's always a simpler summation to perform. In half of the possible products, one only has to add the sum of the digits to zero. For the rest, just slot the 2nd digit of the sum where the zero goes, and add 1 to the first digit. Most people can do either of those two simple additions faster than they can do sums like 210+21 or 390+39. If one is already quick with the latter kind of addition, then the trick is unnecessary.


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

Search: