結果

問題 No.257 N言っちゃダメゲーム (3)
ユーザー ixTL255ixTL255
提出日時 2016-09-07 22:37:42
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 107 ms / 2,000 ms
コード長 494 bytes
コンパイル時間 2,058 ms
コンパイル使用メモリ 101,540 KB
実行使用メモリ 39,864 KB
平均クエリ数 3.70
最終ジャッジ日時 2023-09-24 00:31:54
合計ジャッジ時間 7,007 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 107 ms
37,360 KB
testcase_01 AC 102 ms
37,572 KB
testcase_02 AC 101 ms
39,528 KB
testcase_03 AC 98 ms
37,716 KB
testcase_04 AC 97 ms
37,704 KB
testcase_05 AC 98 ms
37,484 KB
testcase_06 AC 103 ms
38,004 KB
testcase_07 AC 100 ms
39,644 KB
testcase_08 AC 98 ms
37,532 KB
testcase_09 AC 99 ms
37,632 KB
testcase_10 AC 99 ms
37,736 KB
testcase_11 AC 98 ms
38,228 KB
testcase_12 AC 97 ms
39,404 KB
testcase_13 AC 96 ms
38,096 KB
testcase_14 AC 99 ms
38,024 KB
testcase_15 AC 98 ms
39,528 KB
testcase_16 AC 99 ms
37,652 KB
testcase_17 AC 98 ms
36,056 KB
testcase_18 AC 99 ms
37,412 KB
testcase_19 AC 102 ms
37,716 KB
testcase_20 AC 102 ms
37,804 KB
testcase_21 AC 99 ms
37,840 KB
testcase_22 AC 100 ms
38,112 KB
testcase_23 AC 100 ms
39,864 KB
testcase_24 AC 101 ms
39,436 KB
testcase_25 AC 101 ms
37,392 KB
testcase_26 AC 101 ms
38,020 KB
testcase_27 AC 99 ms
39,492 KB
testcase_28 AC 99 ms
39,832 KB
testcase_29 AC 102 ms
37,876 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;
using System.Collections.Generic;
using System.Linq;

public class Test
{
	public static void Main()
	{
		var list = Console.ReadLine()
					.Split(' ')
					.Select(x => int.Parse(x))
					.ToList();
		var n = list[0];
		var k = list[1];
		var next = (n - 1) % (k + 1);
		
		Console.WriteLine(next);
		next += k + 1;
		
		while(true)
		{
			var d = int.Parse(Console.ReadLine());
			
			if(d >= n) break;
			else
			{
				Console.WriteLine(next);
				next += k + 1;
			}
		}
	}
}
0