Coders Packet

Check whether the given number is a prime or not using C

By Varshini S

A prime number is a natural number that has only one and itself as factors. Examples: 2, 3, 13 are prime numbers.

A prime number is a natural number that separates only one. The numerical feature is the number I can divide. The list of the first ten leading numbers is 2,3,5,7,11,13,17,23,29,31.

If the non-primary number is a combined number. Combined number is a number that can be divided by any number. In the first compound number there is one that is not a Prime number or a combination because it can only be divided into one.

To check whether the number is moving there are two factors to consider

1) It should be a whole number greater than 1.

2) It should be divided into two parts which means one and the number itself.

If both scenarios are satisfactory, then we can say that the number is the prime number.

Download Complete Code


No comments yet