17632022-12-02 20:01:21levente19Oszthatóság 17-tel (60 pont)cpp11Accepted 60/603ms4124 KiB
#include <bits/stdc++.h>
#define gyorsan ios::sync_with_stdio(0);cin.tie(0)

using namespace std;

int main()
{
    gyorsan;

    long long n;

    cin >> n;

    if(n % 17 == 0) cout << "IGEN" << endl;
    else cout << "NEM" << endl;

    while(n > 0) {
        int lastDigit = n % 10;
        n = n / 10 - lastDigit*5;
        if(n >= 0) cout << n << " ";
    }

    cout << endl;

    return 0;
}
SubtaskSumTestVerdictTimeMemory
base60/60
1Accepted0/03ms1900 KiB
2Accepted0/02ms2264 KiB
3Accepted3/32ms2352 KiB
4Accepted3/32ms2424 KiB
5Accepted4/42ms2512 KiB
6Accepted4/42ms2584 KiB
7Accepted4/42ms2588 KiB
8Accepted5/52ms2776 KiB
9Accepted5/52ms3016 KiB
10Accepted5/52ms3360 KiB
11Accepted5/52ms3480 KiB
12Accepted6/62ms3680 KiB
13Accepted6/62ms3764 KiB
14Accepted6/62ms3972 KiB
15Accepted2/22ms4012 KiB
16Accepted2/22ms4124 KiB