C++ Program To Check Whether a Number is Prime or not
Given a positive integer N. The task is to write a C++ program to check if the number is prime or not. Definition: A prime number is a natural number greater than 1 that has no positive divisors other than 1 and itself. The first few prime numbers are {2, 3, 5, 7, 11, ....} The idea to solve this