結果

問題 No.1210 XOR Grid
ユーザー 37zigen37zigen
提出日時 2020-08-30 14:19:41
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 392 ms / 2,000 ms
コード長 289 bytes
コンパイル時間 503 ms
コンパイル使用メモリ 82,460 KB
実行使用メモリ 267,932 KB
最終ジャッジ日時 2024-04-27 07:27:31
合計ジャッジ時間 10,223 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 38 ms
53,256 KB
testcase_01 AC 38 ms
51,996 KB
testcase_02 AC 41 ms
58,000 KB
testcase_03 AC 38 ms
52,992 KB
testcase_04 AC 38 ms
53,096 KB
testcase_05 AC 39 ms
52,464 KB
testcase_06 AC 39 ms
53,016 KB
testcase_07 AC 39 ms
53,172 KB
testcase_08 AC 38 ms
51,940 KB
testcase_09 AC 39 ms
52,264 KB
testcase_10 AC 38 ms
53,436 KB
testcase_11 AC 39 ms
53,472 KB
testcase_12 AC 39 ms
52,280 KB
testcase_13 AC 38 ms
53,368 KB
testcase_14 AC 38 ms
52,336 KB
testcase_15 AC 38 ms
52,892 KB
testcase_16 AC 38 ms
53,040 KB
testcase_17 AC 38 ms
53,104 KB
testcase_18 AC 38 ms
52,624 KB
testcase_19 AC 38 ms
52,432 KB
testcase_20 AC 38 ms
53,488 KB
testcase_21 AC 39 ms
52,368 KB
testcase_22 AC 38 ms
53,100 KB
testcase_23 AC 39 ms
54,092 KB
testcase_24 AC 39 ms
53,572 KB
testcase_25 AC 244 ms
199,568 KB
testcase_26 AC 221 ms
196,292 KB
testcase_27 AC 218 ms
196,160 KB
testcase_28 AC 226 ms
197,744 KB
testcase_29 AC 108 ms
108,752 KB
testcase_30 AC 102 ms
98,904 KB
testcase_31 AC 110 ms
108,756 KB
testcase_32 AC 110 ms
107,304 KB
testcase_33 AC 39 ms
53,028 KB
testcase_34 AC 39 ms
52,756 KB
testcase_35 AC 39 ms
54,160 KB
testcase_36 AC 190 ms
189,092 KB
testcase_37 AC 185 ms
182,256 KB
testcase_38 AC 193 ms
192,640 KB
testcase_39 AC 136 ms
144,684 KB
testcase_40 AC 327 ms
260,500 KB
testcase_41 AC 335 ms
260,632 KB
testcase_42 AC 378 ms
267,932 KB
testcase_43 AC 346 ms
259,612 KB
testcase_44 AC 378 ms
267,924 KB
testcase_45 AC 392 ms
267,760 KB
testcase_46 AC 375 ms
265,868 KB
testcase_47 AC 115 ms
115,848 KB
testcase_48 AC 118 ms
115,940 KB
testcase_49 AC 43 ms
58,740 KB
testcase_50 AC 204 ms
170,784 KB
testcase_51 AC 169 ms
134,784 KB
testcase_52 AC 157 ms
129,472 KB
testcase_53 AC 157 ms
128,400 KB
testcase_54 AC 112 ms
115,912 KB
testcase_55 AC 142 ms
134,268 KB
testcase_56 AC 117 ms
110,496 KB
testcase_57 AC 139 ms
126,072 KB
testcase_58 AC 41 ms
53,088 KB
testcase_59 AC 40 ms
52,884 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

MOD=10**9+7
N,M,X=map(int,input().split())
A=list(map(int,input().split()))
B=list(map(int,input().split()))
ans=1
for x in range(X):
    a=[(v>>x)%2 for v in A]
    b=[(v>>x)%2 for v in B]
    if sum(a)%2!=sum(b)%2:
        exit(print(0))
    ans=ans*pow(2,(N-1)*(M-1),MOD)%MOD
print(ans)
0