Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- int n;
- cout << "Nhap n: ";
- cin >> n;
- bool c = false;
- int t = n;
- while (t > 0)
- {
- int dv = t % 10;
- if (dv % 2 != 0)
- c = true;
- t = t / 10;
- }
- if (c)
- cout << "Ton tai chu so le." << endl;
- else
- cout << "Khong ton tai chu so le." << endl;
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement