結果
| 問題 | No.29 パワーアップ |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2017-10-27 17:16:42 |
| 言語 | Python3 (3.14.3 + numpy 2.4.4 + scipy 1.17.1) |
| 結果 |
AC
|
| 実行時間 | 91 ms / 5,000 ms |
| + 797µs | |
| コード長 | 266 bytes |
| 記録 | |
| コンパイル時間 | 284 ms |
| コンパイル使用メモリ | 21,540 KB |
| 実行使用メモリ | 15,868 KB |
| 最終ジャッジ日時 | 2026-07-15 21:56:34 |
| 合計ジャッジ時間 | 3,690 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 22 |
ソースコード
from collections import Counter
#inp
n=int(input())
items=[]
up=0
for _ in range(n):
items+=input().split()
#exe
dic_items=Counter(items)
for (i,j) in dic_items.items():
up+=j//2
dic_items[i]=j%2
up+=sum(list(dic_items.values())) //4
print(up)