Menu

[solved] – Question 80070

Write a function sumprimes(l) that takes as input a list of integers l and retuns the sum of all the prime numbers in l.

Here are some examples to show how your function should work.

>>> sumprimes([3,3,1,13])
19
>>> sumprimes([2,4,6,9,11])
13
>>> sumprimes([-3,1,6])
0

Expert Answer


OR


Leave a Reply

Your email address will not be published. Required fields are marked *