Computer Science, asked by anaghadevadas0084, 4 months ago

python program to generate prime numbers upto N. N is the user input number​

Answers

Answered by ks1923794
0

Answer:

rate prime numbers upto N. N

Explanation:

Answered by atrs7391
0

n = int(input("Enter value of N: "))

for num in range(1, n + 1):

   if num > 1:

       for i in range(2, num):

           if num % i == 0:

               break

       else:

           print(num)

Similar questions