結果

問題 No.183 たのしい排他的論理和(EASY)
ユーザー Navier_BoltzmannNavier_Boltzmann
提出日時 2024-02-25 00:03:54
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 4,090 ms / 5,000 ms
コード長 300 bytes
コンパイル時間 217 ms
コンパイル使用メモリ 81,700 KB
実行使用メモリ 259,276 KB
最終ジャッジ日時 2024-02-25 00:04:16
合計ジャッジ時間 21,004 ms
ジャッジサーバーID
(参考情報)
judge12 / judge16
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 44 ms
55,596 KB
testcase_01 AC 44 ms
55,596 KB
testcase_02 AC 51 ms
64,064 KB
testcase_03 AC 48 ms
61,700 KB
testcase_04 AC 45 ms
55,596 KB
testcase_05 AC 51 ms
65,600 KB
testcase_06 AC 44 ms
55,596 KB
testcase_07 AC 4,090 ms
259,276 KB
testcase_08 AC 2,295 ms
194,052 KB
testcase_09 AC 1,629 ms
171,448 KB
testcase_10 AC 1,884 ms
181,508 KB
testcase_11 AC 2,489 ms
199,876 KB
testcase_12 AC 53 ms
68,928 KB
testcase_13 AC 43 ms
55,596 KB
testcase_14 AC 53 ms
68,312 KB
testcase_15 AC 2,594 ms
202,492 KB
testcase_16 AC 48 ms
61,700 KB
testcase_17 AC 660 ms
140,516 KB
testcase_18 AC 3,243 ms
259,004 KB
testcase_19 AC 343 ms
132,000 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from collections import *
from itertools import *
from functools import *
from heapq import *
import sys, math

input = sys.stdin.readline


N = int(input())
A = list(map(int, input().split()))
X = set([0])
for a in A:
    Y = set(X)
    for x in X:
        Y.add(x ^ a)
    X = set(Y)
print(len(X))
0