20912022-12-19 08:43:04szabel26Oszthatóság 31-gyelcpp17Wrong answer 48/503ms3372 KiB
#include <iostream>
#include <vector>

using namespace std;

long long n,k;

vector<long long>sz;

int main()
{
    cin>>n;
    if(n%31==0) cout<<"IGEN"<<"\n";
        else cout<<"NEM"<<"\n";

    while (n>0)
    {
        k=n%10;
        n/=10;
        n-=3*k;
        if(n>=0) sz.push_back(n);
    }

    for(auto &e:sz) cout<<e<<" ";
}
SubtaskSumTestVerdictTimeMemory
base48/50
1Accepted0/03ms1748 KiB
2Accepted0/02ms1912 KiB
3Accepted3/32ms2116 KiB
4Accepted3/32ms2316 KiB
5Accepted4/42ms2520 KiB
6Accepted4/42ms2728 KiB
7Accepted4/42ms2800 KiB
8Accepted4/42ms2932 KiB
9Accepted4/42ms3008 KiB
10Accepted4/42ms3008 KiB
11Accepted4/42ms3116 KiB
12Accepted4/42ms3360 KiB
13Accepted4/42ms3372 KiB
14Accepted4/42ms3368 KiB
15Accepted2/22ms3212 KiB
16Wrong answer0/22ms3336 KiB