View Single Post
Old Jan 22nd, 2008, 3:19 PM   #20
Sane
Programming Guru
 
Sane's Avatar
 
Join Date: Apr 2005
Location: Waterloo, Ontario
Posts: 1,885
Rep Power: 5 Sane will become famous soon enough
Send a message via MSN to Sane
Re: Exception handling: point is...?

I can't tell if you were agreeing or disagreeing with me, but either way, your new code handles n=2 properly now. Your old code returned false when n % 2 == 0. That was incorrect, since 2 is a prime number.

Anyways, you have it now.
Sane is offline   Reply With Quote