Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <conio.h>
- #include <cmath>
- using namespace std;
- int main()
- {
- int n,i;
- cout<<"nhap n=";
- cin>>n;
- int laSNT=1;
- for (i=0;i<=sqrt(n) && laSNT;i++)
- laSNT=n%i;
- if (laSNT)
- cout<<n<<" la so nguyen to";
- getch();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement