Untitled

mail@pastecode.io avatar
unknown
plain_text
2 years ago
493 B
0
Indexable
Never
#include <iostream>
using namespace std;

int main()
{
    int a, b, c;
    cin >> a;
    if (a == 4 || a == 1) cout << "Yes";
    else 
    {
        while (true)
        {
            b += 1;
            c = b * 2 + (b - 2) * 2;
            if (c == a)
            {
                cout << "Yes";
                break;
            }
            else if (c > a)
            {
                cout << "No";
                break;
            }
        }
    }
}