[Tutor] prime test problem
Roelof Wobben
rwobben at hotmail.com
Sat Aug 21 16:58:31 CEST 2010
Hello,
I forget to mention that I try to follow this book : Think like a computer scientist and I'm now working on chapter 4.
Roelof
From: rwobben at hotmail.com
To: tutor at python.org
Date: Sat, 21 Aug 2010 14:41:03 +0000
Subject: Re: [Tutor] prime test problem
Hello,
I know.
I have read them all I believe but I can't see how I can convert the algebra to a working programm.
Roelof
Date: Sat, 21 Aug 2010 19:15:03 +0530
Subject: Re: [Tutor] prime test problem
From: nitin.162 at gmail.com
To: rwobben at hotmail.com
CC: tutor at python.org
For this problem u will get lots of solutions on the net.
e.g wilson's theorem , sieve of eranthoses etc.
--nitin
On Sat, Aug 21, 2010 at 7:05 PM, Roelof Wobben <rwobben at hotmail.com> wrote:
Hello,
I have to make a programm which can test if a number is a prime.
I know a prime is a number which can only be diveded by 1 and itself.
One way is was thinking about is to make a loop which try if % has output 0.
But that don't work.
Can someone give me a hint what's the best approach is.
Roelof
_______________________________________________
Tutor maillist - Tutor at python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
_______________________________________________ Tutor maillist - Tutor at python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20100821/e0900cb4/attachment-0001.html>
More information about the Tutor
mailing list