結果
問題 |
No.2672 Subset Xor Sum
|
ユーザー |
![]() |
提出日時 | 2024-03-15 21:29:02 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 301 bytes |
コンパイル時間 | 205 ms |
コンパイル使用メモリ | 82,296 KB |
実行使用メモリ | 63,052 KB |
最終ジャッジ日時 | 2024-09-30 00:24:25 |
合計ジャッジ時間 | 4,661 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 52 WA * 14 |
ソースコード
N=int(input()) if N>=15: print('Yes') exit() p=list(map(int,input().split())) from itertools import product for A in product(range(2),repeat=N): ans=0 count=0 for i in range(N): if A[i]==1: ans^=p[i] count+=1 if 0<count<N and ans==0: print('Yes') exit() print('No')