Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- void check(int a)
- {
- bool found = false;
- for (int i=1; i<32000; ++i)
- {
- if (a == 180-360/i)
- {
- cout << "TAK" << endl;
- found = true;
- break;
- }
- }
- if (found == false)
- {
- cout << "NIE" << endl;
- }
- }
- int main ()
- {
- int n;
- cin >> n;
- for (int i=0; i<n; ++i)
- {
- int a;
- cin >> a;
- check(a);
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement