#P202. 练33.2 素数判断
练33.2 素数判断
Description
One day, Nick gave Glaire several numbers and asked her to determine if they were prime numbers. Now, please write a program that takes a natural number as input and determines whether it is prime.
Note: A natural number greater than is prime if it has exactly two factors ( and itself). Otherwise, it is composite. Specifically, is neither prime nor composite.
Input Format
A single line containing an integer.
Output Format
A single line: output "Y" if the number is prime; otherwise, output "N".
Sample
18N