Joined
Last Seen
0 Reputation Points
Unknown Quality Score
No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
0 Endorsements
Ranked #107.40K
#include<iostream> using namespace std; int main() { int a,d; cout<<"Enter a integer to check it is prime or not :"; cin>>a; d=2; while(a%d!=0) { d++; } if(a==d) { cout<<"\n the given number id prime "; } else cout<<"\n the given number is not a prime number ;" return 0; } |