結果

問題 No.706 多眼生物の調査
ユーザー superzugansuperzugan
提出日時 2021-08-28 02:19:39
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 500 bytes
コンパイル時間 460 ms
コンパイル使用メモリ 10,724 KB
実行使用メモリ 8,188 KB
最終ジャッジ日時 2023-08-13 14:21:42
合計ジャッジ時間 1,399 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 WA -
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

n=int(input())
lst=[]
for i in range(n):
    tmp=0
    s=input()
    for j in s:
        if j=="(":continue
        if j=="^":tmp+=1
        elif j==")":
            lst.append(tmp)
            # print(lst)
            break
def zen(lst):
    ans_lst=dict()
    for i in lst:
        if i not in ans_lst:
            ans_lst[i]=1
        else:ans_lst[i]+=1
    return ans_lst
# print(zen(lst))
zz=zen(lst)
zz1=sorted(zz.items(),reverse=True,key=lambda x:(x[1],x[0]))
print(zz1[0][0])
print(zz1[:10])
0