結果

問題 No.182 新規性の虜
ユーザー tarotaro789
提出日時 2017-03-16 22:24:07
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 266 bytes
コンパイル時間 86 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 20,588 KB
最終ジャッジ日時 2024-07-04 02:44:51
合計ジャッジ時間 3,315 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 24 WA * 3
権限があれば一括ダウンロードができます

ソースコード

diff #

n=int(input())
ls=list(map(int,input().split()))
ls.sort()
cnt=0
for i in range(n-2):
    if i==0:
        if ls[i]!=ls[i+1]:
            cnt+=1
    if i==n-3:
        if ls[i+1]!=ls[i+2]:
            cnt+=1
    if ls[i]!=ls[i+1]!=ls[i+2]:
        cnt+=1
print(cnt)
0