36172023-03-01 10:53:20tothgergelyOszthatóság 17-tel (60 pont)csharpAccepted 60/6028ms24140 KiB
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _17
{
    class Program
    {
        static void Main(string[] args)
        {
            int n = Convert.ToInt32(Console.ReadLine());
            int a = 0;
            List<int> l = new List<int>();
            if (n  % 17 == 0)
            {
                Console.WriteLine("IGEN"); 
            }
            else
            {
                Console.WriteLine("NEM");
            }
            while (n > 0)
            {
                    a = n % 10;
                    n = n / 10 - a * 5;
                    
                if (n < 0)
                {
                    break;
                }
                l.Add(n);
            }

            if (l.Count > 0)
            { 
                foreach (var i in l)
                {
                    Console.Write(i + " ");
                }
            }
            else
            {
                Console.WriteLine();
            }

            Console.ReadKey();
        }
    }
}
SubtaskSumTestVerdictTimeMemory
base60/60
1Accepted0/028ms20624 KiB
2Accepted0/028ms21036 KiB
3Accepted3/328ms21136 KiB
4Accepted3/328ms21548 KiB
5Accepted4/428ms21628 KiB
6Accepted4/428ms22316 KiB
7Accepted4/428ms22748 KiB
8Accepted5/528ms22748 KiB
9Accepted5/528ms22828 KiB
10Accepted5/528ms23152 KiB
11Accepted5/527ms23380 KiB
12Accepted6/627ms23764 KiB
13Accepted6/628ms23852 KiB
14Accepted6/628ms23856 KiB
15Accepted2/227ms23892 KiB
16Accepted2/227ms24140 KiB