#include <iostream>
using namespace std;
int main()
{
int n,d1,d2,d3;
cin>>n;
if(n<0)
n=(-1)*n;
if (n>99 && n<1000)
d1=n/100;
d3=n%10;
d2=(n%100)/10;
if(d1%2==0 && d2%2==0 && d3%2==0)
cout<<"yes";
else
cout<<"no";
}
cout<<"incorrect number";
return 0;
int amountNum(int a)
int count = 0;
while(a > 0)
a /= 10;
count++;
return count;
bool check(int a)
int k = a % 10;
if(k % 2 != 0)
return false;
return true;
int num;
cin >> num;
if(amountNum(num) != 3)
cout << "Incorrect input";
if(check(num))
cout << "YES";
cout << "NO";
#include <iostream>
using namespace std;
int main()
{
int n,d1,d2,d3;
cin>>n;
if(n<0)
n=(-1)*n;
if (n>99 && n<1000)
{
d1=n/100;
d3=n%10;
d2=(n%100)/10;
if(d1%2==0 && d2%2==0 && d3%2==0)
cout<<"yes";
else
cout<<"no";
}
else
cout<<"incorrect number";
return 0;
}
#include <iostream>
using namespace std;
int amountNum(int a)
{
int count = 0;
while(a > 0)
{
a /= 10;
count++;
}
return count;
}
bool check(int a)
{
while(a > 0)
{
int k = a % 10;
if(k % 2 != 0)
return false;
a /= 10;
}
return true;
}
int main()
{
int num;
cin >> num;
if(amountNum(num) != 3)
{
cout << "Incorrect input";
return 0;
}
if(check(num))
cout << "YES";
else
cout << "NO";
}