結果
問題 |
No.564 背の順
|
ユーザー |
|
提出日時 | 2020-08-27 19:31:27 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 44 ms / 2,000 ms |
コード長 | 349 bytes |
コンパイル時間 | 195 ms |
コンパイル使用メモリ | 82,176 KB |
実行使用メモリ | 52,608 KB |
最終ジャッジ日時 | 2024-11-08 00:41:31 |
合計ジャッジ時間 | 1,338 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 9 |
ソースコード
H, N = map(int, input().split()) from bisect import bisect h = [int(input()) for i in range(N - 1)] h.sort() ans = N - bisect(h, H) if ans % 10 == 1: print(ans, 'st', sep='') elif ans % 10 == 2: print(ans, 'nd', sep='') elif ans % 10 == 3: print(ans, 'rd', sep='') else: print(ans, 'th', sep='')