Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- print ( "Prime number program ")
- user_input = input ( " Enter a number greater than 1 - ")
- user_input = int(user_input)
- for i in range ( 2, user_input):
- if user_input % i == 0:
- print ( user_input, " is not a prime number")
- print ( "it is divisible by", i)
- break
- else:
- print ( user_input, "is a prime number")
Add Comment
Please, Sign In to add comment