COM1001 – COMPUTER ENGINEERING DEPARTMENT (Solution)

$ 24.99
Category:

Description

Computer Programming 1
LAB1 Quiz
Assoc. Prof. Dr. Hacer YALIM KELEŞ

A prime number (or prime) is a natural number greater than 1 that has no positive divisors other than 1 and itself.
Write a Python program which takes a set of positive numbers from the input and returns the sum of the prime numbers in the given set. The sequence will be ended with a negative number.
I/O Format:
Input format: [numbers]*[Space]<nega1ve number>
Output format:<sum_of_primes>
Note that:
1- Sample input and output files are provided.
2- [x]* means, zero or more elements of x
Submission:
1- Name your Python source file as <student_id>.py; replace <sIuent_id> using your student id number.
2- Upload your python file using the interface provided in e-kampüs course page.
Please, PAY ATTENTION TO THE I/O FORMAT!

Reviews

There are no reviews yet.

Be the first to review “COM1001 – COMPUTER ENGINEERING DEPARTMENT (Solution)”

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