81172024-01-12 14:00:43czbendeOszthatóság 17-tel (60 pont)csharpRuntime error 51/6028ms23316 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 = int.Parse(Console.ReadLine());
            int n2 = n / 10 - (n % 10) * 5;
            int[] a = new int[100];
            a[0] = n2;
            int i = 1;
            while (n2 >= 0)
            {
                
                n2 = n2 / 10 - (n2 % 10) * 5;
                if (n2 >= 0)
                {
                    
                    a[i] = n2;
                    i++;
                }
            }
            if (n2 % 17 == 0)
            {
                Console.WriteLine("IGEN");

            }
            else
            {
                Console.WriteLine("NEM");
            }
            for (int j = 0; j < i; j++)
            {
                Console.Write(a[j] + " ");

            }
            Console.ReadKey();
        }
    }
}
SubtaskSumTestVerdictTimeMemory
base51/60
1Accepted0/027ms20412 KiB
2Accepted0/026ms20948 KiB
3Accepted3/326ms21440 KiB
4Accepted3/326ms21640 KiB
5Accepted4/427ms22044 KiB
6Accepted4/426ms22636 KiB
7Accepted4/426ms22720 KiB
8Accepted5/527ms22428 KiB
9Runtime error0/528ms22292 KiB
10Accepted5/526ms23016 KiB
11Accepted5/527ms22692 KiB
12Accepted6/627ms22860 KiB
13Accepted6/627ms22820 KiB
14Accepted6/628ms23156 KiB
15Wrong answer0/227ms23268 KiB
16Wrong answer0/227ms23316 KiB