結果

問題 No.1380 Borderline
ユーザー さかぽんさかぽん
提出日時 2021-02-16 23:20:08
言語 C#(csc)
(csc 3.9.0)
結果
RE  
実行時間 -
コード長 396 bytes
コンパイル時間 3,043 ms
コンパイル使用メモリ 103,216 KB
実行使用メモリ 23,032 KB
最終ジャッジ日時 2023-10-11 12:56:07
合計ジャッジ時間 7,908 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 60 ms
20,848 KB
testcase_01 AC 59 ms
22,880 KB
testcase_02 AC 59 ms
20,792 KB
testcase_03 AC 60 ms
22,884 KB
testcase_04 AC 60 ms
20,708 KB
testcase_05 AC 57 ms
20,988 KB
testcase_06 AC 59 ms
20,980 KB
testcase_07 RE -
testcase_08 AC 59 ms
20,856 KB
testcase_09 RE -
testcase_10 RE -
testcase_11 AC 59 ms
20,776 KB
testcase_12 AC 59 ms
20,972 KB
testcase_13 AC 59 ms
22,744 KB
testcase_14 AC 67 ms
20,776 KB
testcase_15 AC 67 ms
20,952 KB
testcase_16 AC 66 ms
20,772 KB
testcase_17 AC 66 ms
20,796 KB
testcase_18 AC 66 ms
20,980 KB
testcase_19 AC 66 ms
20,996 KB
testcase_20 AC 67 ms
21,104 KB
testcase_21 AC 66 ms
20,780 KB
testcase_22 AC 67 ms
20,892 KB
testcase_23 AC 66 ms
20,852 KB
testcase_24 AC 66 ms
20,884 KB
testcase_25 AC 67 ms
22,908 KB
testcase_26 AC 66 ms
20,904 KB
testcase_27 AC 66 ms
23,012 KB
testcase_28 AC 66 ms
20,960 KB
testcase_29 AC 66 ms
20,844 KB
testcase_30 AC 66 ms
20,792 KB
testcase_31 AC 66 ms
21,060 KB
testcase_32 AC 66 ms
20,964 KB
testcase_33 AC 67 ms
22,820 KB
testcase_34 AC 67 ms
20,960 KB
testcase_35 AC 67 ms
20,924 KB
testcase_36 AC 66 ms
23,032 KB
testcase_37 AC 66 ms
18,952 KB
testcase_38 AC 66 ms
20,952 KB
testcase_39 AC 67 ms
22,996 KB
testcase_40 AC 66 ms
20,992 KB
testcase_41 AC 66 ms
21,072 KB
testcase_42 AC 66 ms
20,804 KB
testcase_43 AC 66 ms
20,952 KB
testcase_44 RE -
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;

class A
{
	static int[] Read() => Array.ConvertAll(Console.ReadLine().Split(), int.Parse);
	static (int, int) Read2() { var a = Read(); return (a[0], a[1]); }
	static void Main()
	{
		var (n, k) = Read2();
		var p = Read();

		if (n == 1) { Console.WriteLine(1); return; }

		Array.Sort(p);
		Array.Reverse(p);
		while (k > 0 && p[k - 1] == p[k]) k--;
		Console.WriteLine(k);
	}
}
0