結果
| 問題 |
No.1091 Range Xor Query
|
| ユーザー |
|
| 提出日時 | 2020-06-24 07:09:09 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 426 ms / 2,000 ms |
| コード長 | 251 bytes |
| コンパイル時間 | 464 ms |
| コンパイル使用メモリ | 64,004 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-07-03 19:55:55 |
| 合計ジャッジ時間 | 10,079 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 27 |
コンパイルメッセージ
main.cpp:4:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
4 | main()
| ^~~~
ソースコード
#include<iostream>
using namespace std;
int N,Q,A[2<<17];
main()
{
cin>>N>>Q;
for(int i=1;i<=N;i++)
{
cin>>A[i];
A[i]^=A[i-1];
}
for(;Q--;)
{
int l,r;cin>>l>>r;
cout<<(A[r]^A[l-1])<<endl;
}
}