結果

問題 No.182 新規性の虜
ユーザー iad_2889iad_2889
提出日時 2019-05-02 03:57:16
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 521 bytes
コンパイル時間 332 ms
コンパイル使用メモリ 10,688 KB
実行使用メモリ 15,064 KB
最終ジャッジ日時 2023-08-30 04:35:54
合計ジャッジ時間 8,767 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 AC 16 ms
7,752 KB
testcase_03 AC 16 ms
7,712 KB
testcase_04 AC 16 ms
7,708 KB
testcase_05 AC 16 ms
7,708 KB
testcase_06 AC 16 ms
7,768 KB
testcase_07 AC 16 ms
7,816 KB
testcase_08 AC 40 ms
15,064 KB
testcase_09 OLE -
testcase_10 -- -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
testcase_14 -- -
testcase_15 -- -
testcase_16 -- -
testcase_17 -- -
testcase_18 -- -
testcase_19 -- -
testcase_20 -- -
testcase_21 -- -
testcase_22 -- -
testcase_23 -- -
testcase_24 -- -
testcase_25 -- -
testcase_26 -- -
testcase_27 -- -
evil01.txt -- -
evil02.txt -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
nums = [int(x) for x in input().split()]
num_type = set(nums)
if len(num_type) == N:
    newly = N
else:
    newly = 0
    current = None
    while nums:
        current = nums.pop(0)
        print(current)
        print(nums)
        if current in nums:
            idxs = []
            for idx,num in enumerate(nums):
                if num == current:
                    idxs.insert(0,idx)
            for idx in idxs:
                del nums[idx]
        else:
            newly +=1

print(newly)
0