Computer Science, asked by prathyushaimandi, 8 months ago

prime number code in while loop​

Answers

Answered by arunk965774
1

Answer:

I didn't know that bro...

Answered by sambhavgautam6
0

Explanation:

  • #prime number using while loop
  • num= int(input("Enter the value"))
  • flag=0
  • n=num
  • while n>1 and n= n-1 :
  • if num%n==0:
  • flag==0
  • break
  • if flag==0:
  • print("not a prime number")
  • else :
  • print ("a prime number")

please mark as brainliest

Similar questions
Math, 4 months ago