結果

問題 No.1082 XORのXOR
ユーザー NagisaNagisa
提出日時 2020-06-19 21:30:24
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 482 ms / 2,000 ms
コード長 311 bytes
コンパイル時間 148 ms
コンパイル使用メモリ 10,788 KB
実行使用メモリ 8,428 KB
最終ジャッジ日時 2023-09-16 13:29:31
合計ジャッジ時間 13,342 ms
ジャッジサーバーID
(参考情報)
judge11 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
7,804 KB
testcase_01 AC 16 ms
7,824 KB
testcase_02 AC 15 ms
7,732 KB
testcase_03 AC 479 ms
8,384 KB
testcase_04 AC 479 ms
8,244 KB
testcase_05 AC 479 ms
8,300 KB
testcase_06 AC 481 ms
8,344 KB
testcase_07 AC 481 ms
8,240 KB
testcase_08 AC 477 ms
8,300 KB
testcase_09 AC 479 ms
8,328 KB
testcase_10 AC 478 ms
8,328 KB
testcase_11 AC 476 ms
8,400 KB
testcase_12 AC 479 ms
8,236 KB
testcase_13 AC 478 ms
8,428 KB
testcase_14 AC 482 ms
8,308 KB
testcase_15 AC 480 ms
8,176 KB
testcase_16 AC 478 ms
8,256 KB
testcase_17 AC 480 ms
8,292 KB
testcase_18 AC 480 ms
8,328 KB
testcase_19 AC 476 ms
8,236 KB
testcase_20 AC 479 ms
8,392 KB
testcase_21 AC 479 ms
8,236 KB
testcase_22 AC 481 ms
8,328 KB
testcase_23 AC 477 ms
8,328 KB
testcase_24 AC 479 ms
8,336 KB
testcase_25 AC 481 ms
8,300 KB
testcase_26 AC 481 ms
8,368 KB
testcase_27 AC 478 ms
8,256 KB
testcase_28 AC 16 ms
7,816 KB
testcase_29 AC 16 ms
7,900 KB
testcase_30 AC 15 ms
7,732 KB
testcase_31 AC 15 ms
7,808 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
def input():
    return sys.stdin.readline()[:-1]
def main():
    MOD = 10**9 + 7
    N = int(input())
    A = list(map(int,input().split()))
    ans = 0
    for i in range(N-1):
        for j in range(i+1,N):
            ans = max(ans,A[i]^A[j])
    print(ans)
if __name__ == '__main__':
    main()
0