結果
| 問題 | No.564 背の順 |
| コンテスト | |
| ユーザー |
turner18_jp
|
| 提出日時 | 2017-10-01 16:35:58 |
| 言語 | Python3 (3.14.3 + numpy 2.4.4 + scipy 1.17.1) |
| 結果 |
AC
|
| 実行時間 | 95 ms / 2,000 ms |
| コード長 | 522 bytes |
| 記録 | |
| コンパイル時間 | 549 ms |
| コンパイル使用メモリ | 20,824 KB |
| 実行使用メモリ | 15,360 KB |
| 最終ジャッジ日時 | 2026-05-10 22:35:06 |
| 合計ジャッジ時間 | 2,501 ms |
|
ジャッジサーバーID (参考情報) |
judge2_1 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 9 |
ソースコード
t = input().split()
li = []
li.append(int(t[0]))
for i in range(int(t[1]) - 1):
li.append(int(input()))
li.sort(reverse=True)
for index, value in enumerate(li, start=1):
if int(t[0]) == value:
if index % 10 == 1:
print(str(index) + "st")
break
elif index % 10 == 2:
print(str(index) + "nd")
break
elif index % 10 == 3:
print(str(index) + "rd")
break
else:
print(str(index) + "th")
break
turner18_jp