Hey all,
I am new here and new to python too. In general new to programming .
I was working on aproblem.
and need some help.
I have a list of numbers say [2,3,5,6,10,15]
which all divide number 30.
Now i have to reduce this list to the numbers which are prime in number.
i.e.
[2,3,5]
can somebody
On 24-Jun-11 03:01 AM, kaustubh joshi wrote:
Hey all,
I am new here and new to python too. In general new to programming .
I was working on aproblem.
and need some help.
I have a list of numbers say [2,3,5,6,10,15]
which all divide number 30.
Now i have to reduce this list to the numbers which
You might try writing the boolean function is_prime(n) for almost any n.
There was a recent discussion on this topic.
Since the guy is new in programming, I complete the answer, just in
case. Using the function is_prime(n),
FIRST POSSIBILITY :
new_list=[]
for n in old_list:
if
On Fri, Jun 24, 2011 at 8:01 AM, kaustubh joshi kandrjo...@gmail.com wrote:
Hey all,
I am new here and new to python too. In general new to programming .
I was working on aproblem.
and need some help.
I have a list of numbers say [2,3,5,6,10,15]
which all divide number 30.
Now i have to