結果
問題 | No.188 HAPPY DAY |
ユーザー | Hidetoshi Kamata |
提出日時 | 2022-05-05 17:38:47 |
言語 | C# (.NET 8.0.203) |
結果 |
MLE
(最新)
AC
(最初)
|
実行時間 | - |
コード長 | 481 bytes |
コンパイル時間 | 6,916 ms |
コンパイル使用メモリ | 142,688 KB |
実行使用メモリ | 158,132 KB |
最終ジャッジ日時 | 2023-09-18 02:19:34 |
合計ジャッジ時間 | 7,480 ms |
ジャッジサーバーID (参考情報) |
judge13 / judge11 |
(要ログイン)
コンパイルメッセージ
Determining projects to restore... Restored /home/judge/data/code/main.csproj (in 122 ms). .NET 向け Microsoft (R) Build Engine バージョン 17.0.0-preview-21470-01+cb055d28f Copyright (C) Microsoft Corporation.All rights reserved. プレビュー版の .NET を使用しています。https://aka.ms/dotnet-core-preview をご覧ください main -> /home/judge/data/code/bin/Release/net6.0/main.dll main -> /home/judge/data/code/bin/Release/net6.0/publish/
ソースコード
using System; using System.Linq; class Program { static void Main(string[] args) { int happyDay = 0; int[] days = new int[] { 0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 }; for (int month = 1; month <= 12; month++) { for (int day = 1; day <= days[month]; day++) { if (month == (day % 10) + day / 10) happyDay++; } } Console.WriteLine(happyDay.ToString()); } }