राइट ए प्रोग्राम टो चेक वेदर ए गिवन नंबर इस प्राइम ओर नॉट
Answers
Answer:
A prime number is a number that is divisible only by two numbers itself and one. The factor of a number is a number that can divide it.
The list of the first ten prime numbers is 2,3,5,7,11,13,17,23,29,31.
A number that is not prime is a composite number. A composite number is a number that can be divided by more than two numbers.
Elser then prime and composite there is 1 which is neither Prime nor composite because it can be divided only by itself.
How to check if a number is prime or composite to check if a number is prime there are two conditions that should be checked
1) It should be a whole number greater than 1.
2) it should have only two factors i.e one and the number itself.
If these two conditions are satisfied, then we can say a number is a prime number.
Explanation: