結果
| 問題 |
No.183 たのしい排他的論理和(EASY)
|
| コンテスト | |
| ユーザー |
roknao
|
| 提出日時 | 2020-06-11 01:19:23 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 545 bytes |
| コンパイル時間 | 152 ms |
| コンパイル使用メモリ | 82,184 KB |
| 実行使用メモリ | 88,788 KB |
| 最終ジャッジ日時 | 2024-06-23 21:51:02 |
| 合計ジャッジ時間 | 3,840 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | RE * 2 |
| other | RE * 18 |
ソースコード
from functools import reduce
from fractions import gcd
import math
import bisect
import itertools
import sys
sys.setrecursionlimit(10**7)
input = sys.stdin.readline
INF = float("inf")
MOD = 1000000007
# 処理内容
def main():
N = int(input())
A = list(map(int, input().split()))
num = 16384
dp = [0] * num
dp[0] = 1
for i in range(N):
for j in range(num):
if dp[j] == 1:
dp[j] = 1
dp[j ^ A[i]] = 1
print(sum(dp))
if __name__ == '__main__':
main()
roknao