Sunday, January 19, 2014

Project Euler

This is fun:

"A series of challenging mathematical/computer programming problems that will require more than just mathematical insights to solve."
For example:
"[F]or n with at least one small factor, trial division can be a quick way to find that small factor. For n chosen uniformly at random from integers of a given length, there is a 50% chance that 2 is a factor of n, and a 33% chance that 3 is a factor, and so on. It can be shown that 88% of all positive integers have a factor under 100, and that 92% have a factor under 1000. Thus, when confronted by an arbitrary large n, it is worthwhile to check for divisibility by the small primes."

No comments: