比赛 |
20131026 |
评测结果 |
AAATTTTTTA |
题目名称 |
zwei |
最终得分 |
40 |
用户昵称 |
Holiye |
运行时间 |
6.012 s |
代码语言 |
C++ |
内存使用 |
1.08 MiB |
提交时间 |
2015-09-12 20:28:32 |
显示代码纯文本
#include <iostream>
#include <cstdio>
#include <cmath>
const int maxn=100000+2;
int a[maxn],b[maxn];
int m,n,h,c;
int x,y,z;
using namespace std;
int main()
{
//freopen("test.in","r",stdin);
//freopen("test.out","w",stdout);
freopen("zwei.in","r",stdin);
freopen("zwei.out","w",stdout);
cin>>m>>n;
for(int i=1;i<=m;i++)
{
cin>>a[i];
}
for(int i=1;i<=n;i++)
{
cin>>x>>y>>z;
if(x==0) a[y]=z;
if(x==1)
{
for(int j=y;j<=z;j++)
{
h=h^a[j];
}
cout<<h<<endl;
h=0;
}
}
return 0;
}