36742023-03-02 10:34:33DalmaOszthatóság 17-tel (60 pont)cpp17Wrong answer 9/603ms4056 KiB
#include <iostream>

using namespace std;

int main()
{
    int N;
    cin >> N;
    if (N%17==0)
    {
        cout << "IGEN" << endl;
        int oszthatosag=N;
        int ellenor=0;
        oszthatosag=(oszthatosag/10)-(5*oszthatosag%10);
        while (oszthatosag>=0&&ellenor<1)
        {
            cout << oszthatosag << " ";
            if (oszthatosag==0)
                ellenor++;
            oszthatosag=(oszthatosag/10)-(5*(oszthatosag%10));
        }
    }
    else
    {
        cout << "NEM" << endl;
        int oszthatosag=N;
        int ellenor=0;
        oszthatosag=(oszthatosag/10)-(5*oszthatosag%10);
        while (oszthatosag>=0&&ellenor<1)
        {
            cout << oszthatosag << " ";
            if (oszthatosag==0)
                ellenor++;
            oszthatosag=(oszthatosag/10)-(5*(oszthatosag%10));
        }
    }
    return 0;
}
SubtaskSumTestVerdictTimeMemory
base9/60
1Accepted0/03ms1880 KiB
2Accepted0/02ms2116 KiB
3Wrong answer0/33ms2324 KiB
4Accepted3/32ms2540 KiB
5Wrong answer0/42ms2748 KiB
6Wrong answer0/42ms2792 KiB
7Wrong answer0/42ms2824 KiB
8Wrong answer0/52ms3020 KiB
9Wrong answer0/53ms3136 KiB
10Wrong answer0/52ms3232 KiB
11Wrong answer0/52ms3344 KiB
12Wrong answer0/63ms3460 KiB
13Accepted6/63ms3520 KiB
14Wrong answer0/62ms3728 KiB
15Wrong answer0/22ms3972 KiB
16Wrong answer0/22ms4056 KiB