8112022-01-16 18:01:25dancsakdenesOszthatóság 31-gyelcpp11Accepted 50/502ms2028 KiB
#include <iostream>

using namespace std;
int main()
{
    ios_base::sync_with_stdio(false);
    int n;
    cin>>n;
    int t[10]={};
    int j=0;
    while(n>0)
    {
        n=n/10-3*(n%10);
        if(n>=0)
        {
            j++;
            t[j]=n;
        }
    }
    if(n==0) cout<<"IGEN";
    else cout<<"NEM";
    cout<<endl;
    for(int i=1; i<=j; i++)
    {
        cout<<t[i]<<" ";
    }
	cout << endl;
	return 0;
}
SubtaskSumTestVerdictTimeMemory
base50/50
1Accepted0/02ms1936 KiB
2Accepted0/01ms1924 KiB
3Accepted3/31ms1976 KiB
4Accepted3/31ms1976 KiB
5Accepted4/41ms1988 KiB
6Accepted4/41ms1984 KiB
7Accepted4/41ms1988 KiB
8Accepted4/41ms2000 KiB
9Accepted4/41ms2004 KiB
10Accepted4/41ms2008 KiB
11Accepted4/41ms2008 KiB
12Accepted4/41ms2012 KiB
13Accepted4/41ms2016 KiB
14Accepted4/41ms2024 KiB
15Accepted2/21ms2024 KiB
16Accepted2/21ms2028 KiB