Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <fstream>
- #include <iomanip>
- using namespace std;
- bool temp (int N, int a[]);
- int main ()
- {
- ifstream duom("duom.txt");
- ofstream rez("rez.txt");
- int N, a[3];
- cin>>N;
- for (int i=0;i<3;i++)
- cin>>a[i];
- if (temp(N,a))
- cout<<"LYGINIS";
- else
- cout<<"NELYGINIS";
- return 0;
- }
- bool temp (int N, int a[])
- {
- int x=0;
- for (int i=0; i<3 ;i++)
- {
- if (a[i]% 2!=0)
- x++;
- if (x>1)
- return 1;
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement