81192024-01-12 14:02:11250L7Világnaptár (45 pont)csharpWrong answer 6/4529ms24460 KiB
using System;

namespace vilagnaptar
{
	class Program
	{
		static void Main(string[] args)
		{
			string[] ev = Console.ReadLine().Split(' ');
			if (Convert.ToInt32(ev[0]) % 4 != 0)
			{
				/*if (Convert.ToInt32(ev[1]) == 1 || Convert.ToInt32(ev[1]) == 2)
				{
					Console.WriteLine(ev[0] + " " + ev[1] + " " + ev[2]);
				}
				else if (Convert.ToInt32(ev[1]) == 2 || Convert.ToInt32(ev[2]) < 3)
				{
					Console.WriteLine(ev[0] + " " + (Convert.ToInt32(ev[1]) - 1) + " " + (Convert.ToInt32(ev[2]) + 28));
				}
				else if (Convert.ToInt32(ev[1]) == 3)
				{
					Console.WriteLine(ev[0] + " " + Convert.ToInt32(ev[1]) + " " + (Convert.ToInt32(ev[2]) - 2));
				}
				else if (Convert.ToInt32(ev[1]) == 4 || Convert.ToInt32(ev[2]) < 3)
				{

				}*/
				if (Convert.ToInt32(ev[1]) == 1 || Convert.ToInt32(ev[1]) == 2)
				{
					Console.WriteLine(ev[0] + " " + ev[1] + " " + ev[2]);
				}
				else if (Convert.ToInt32(ev[1]) == 3 && Convert.ToInt32(ev[2]) < 3)
				{
					Console.WriteLine(ev[0] + " " + (Convert.ToInt32(ev[1]) - 1) + " " + (Convert.ToInt32(ev[2]) + 28));
				}
				else if (Convert.ToInt32(ev[1]) == 3)
				{
					Console.WriteLine(ev[0] + " " + ev[1] + " " + (Convert.ToInt32(ev[2]) - 2));
				}
				else if (Convert.ToInt32(ev[1]) == 4 && Convert.ToInt32(ev[2]) == 1)
				{
					Console.WriteLine(ev[0] + " " + (Convert.ToInt32(ev[1]) - 1) + " " + (Convert.ToInt32(ev[2]) + 29));
				}
				else if (Convert.ToInt32(ev[1]) == 4)
				{
					Console.WriteLine(ev[0] + " " + ev[1] + " " + (Convert.ToInt32(ev[2]) - 1));
				}
				else if (Convert.ToInt32(ev[1]) == 5 && Convert.ToInt32(ev[2]) == 1)
				{
					Console.WriteLine(ev[0] + " " + (Convert.ToInt32(ev[1]) - 1) + " " + (Convert.ToInt32(ev[2]) + 30));
				}
				else if (Convert.ToInt32(ev[1]) == 5)
				{
					Console.WriteLine(ev[0] + " " + ev[1] + " " + (Convert.ToInt32(ev[2]) - 1));
				}
				else if (Convert.ToInt32(ev[1]) == 6)
				{
					Console.WriteLine(ev[0] + " " + ev[1] + " " + ev[2]);
				}
				else if (Convert.ToInt32(ev[1]) == 7)
				{
					Console.WriteLine(ev[0] + " " + ev[1] + " " + ev[2]);
				}
				else if (Convert.ToInt32(ev[1]) == 8 && Convert.ToInt32(ev[2]) != 31)
				{
					Console.WriteLine(ev[0] + " " + ev[1] + " " + ev[2]);
				}
				else if (Convert.ToInt32(ev[1]) == 8)
				{
					Console.WriteLine(ev[0] + " " + (Convert.ToInt32(ev[1]) + 1) + " " + (Convert.ToInt32(ev[2]) - 30));
				}
				else if (true)
				{

				}
			}

			Console.ReadKey();
		}
	}
}
SubtaskSumTestVerdictTimeMemory
base6/45
1Wrong answer0/028ms20888 KiB
2Wrong answer0/028ms21212 KiB
3Wrong answer0/028ms21968 KiB
4Wrong answer0/228ms21916 KiB
5Wrong answer0/228ms22408 KiB
6Wrong answer0/327ms22768 KiB
7Wrong answer0/327ms23040 KiB
8Accepted3/328ms23216 KiB
9Wrong answer0/329ms23492 KiB
10Wrong answer0/328ms23688 KiB
11Wrong answer0/328ms23976 KiB
12Wrong answer0/329ms23780 KiB
13Wrong answer0/328ms23764 KiB
14Wrong answer0/328ms24288 KiB
15Wrong answer0/328ms24276 KiB
16Wrong answer0/328ms24164 KiB
17Accepted3/328ms24460 KiB
18Wrong answer0/227ms24424 KiB
19Wrong answer0/328ms24400 KiB