結果
| 問題 |
No.83 最大マッチング
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-09-01 15:45:22 |
| 言語 | C# (.NET 8.0.404) |
| 結果 |
AC
|
| 実行時間 | 69 ms / 5,000 ms |
| コード長 | 758 bytes |
| コンパイル時間 | 9,381 ms |
| コンパイル使用メモリ | 166,560 KB |
| 実行使用メモリ | 186,144 KB |
| 最終ジャッジ日時 | 2024-11-14 06:51:56 |
| 合計ジャッジ時間 | 11,248 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 10 |
コンパイルメッセージ
復元対象のプロジェクトを決定しています... /home/judge/data/code/main.csproj を復元しました (104 ms)。 MSBuild のバージョン 17.9.6+a4ecab324 (.NET) main -> /home/judge/data/code/bin/Release/net8.0/main.dll main -> /home/judge/data/code/bin/Release/net8.0/publish/
ソースコード
using System;
using System.Linq;
using System.Collections.Generic;
using System.Text.RegularExpressions;
class Program
{
static void Main()
{
/*
* 0 : 6
* 1 : 2
* 2 : 5
* 3 : 5
* 4 : 4
* 5 : 5
* 6 : 6
* 7 : 3
* 8 : 7
* 9 : 6
*/
var N = int.Parse(Console.ReadLine());
var _ansList = new List<long>();
while(N != 0)
{
if (N % 2 == 0)
{
N = N - 2;
_ansList.Add(1);
}
else
{
N = N - 3;
_ansList.Add(7);
}
}
Console.WriteLine(String.Join("",_ansList));
}
}