#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
int main(){
cin>>n;
for(int i=1,x;i<=n;i++){
cin>>x;
ans^=x;
}
cout<<ans<<endl;
return 0;
}
2 号选手
#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
int main(){
scanf("%d",&n);
for(int i=1,x;i<=n;i++){
scanf("%d",&x);
ans^=x;
}
printf("%d\n",ans);
return 0;
}
3号选手
#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
int main(){
ios::sync_with_stdio(0);
cin>>n;
for(int i=1,x;i<=n;i++){
cin>>x;
ans^=x;
}
cout<<ans<<endl;
return 0;
}
4号选手
#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
int main(){
cin.tie(0),cout.tie(0);
cin>>n;
for(int i=1,x;i<=n;i++){
cin>>x;
ans^=x;
}
cout<<ans<<endl;
return 0;
}
5 号选手
#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
int main(){
ios::sync_with_stdio(0);
cin.tie(0),cout.tie(0);
cin>>n;
for(int i=1,x;i<=n;i++){
cin>>x;
ans^=x;
}
cout<<ans<<endl;
return 0;
}
6 号选手
#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
int read(){
int k=0,f=1;
char c=getchar();
while(c<'0'||c>'9'){
if(c=='-') f=-1;
c=getchar();
}
while(c>='0'&&c<='9') k=k*10+c-'0',c=getchar();
return k*f;
}
int main(){
n=read();
for(int i=1,x;i<=n;i++){
x=read();
ans^=x;
}
cout<<ans<<endl;
return 0;
}
7 号选手
#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
int read(){
int x=0,f=1;
char ch=getchar();
while(!isdigit(ch)){
if(ch=='-') f=-1;
ch=getchar();
}
while(isdigit(ch)){
x=(x<<1)+(x<<3)+(ch^48);
ch=getchar();
}
return x*f;
}
int main(){
n=read();
for(int i=1,x;i<=n;i++){
x=read();
ans^=x;
}
cout<<ans<<endl;
return 0;
}
8 号选手
#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
inline int read(){
int x=0,f=1;
char ch=getchar();
while(!isdigit(ch)){
if(ch=='-') f=-1;
ch=getchar();
}
while(isdigit(ch)){
x=x*10+ch-'0';
ch=getchar();
}
return x*f;
}
int main(){
n=read();
for(int i=1,x;i<=n;i++){
x=read();
ans^=x;
}
cout<<ans<<endl;
return 0;
}
9 号选手
#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
const int BUFSIZE=1<<20;
char ibuf[BUFSIZE],*is=ibuf,*it=ibuf;
inline char getch(){if(is==it)it=(is=ibuf)+fread(ibuf,1,BUFSIZE,stdin);return is==it?EOF:*is++;}
char tmp[BUFSIZE];int cnt=0;
int read(){
int x=0,f=1;
char ch=getch();
while(!isdigit(ch)){
if(ch=='-') f=-1;
ch=getch();
}
while(isdigit(ch)){
x=x*10+ch-'0';
ch=getch();
}
return x*f;
}
int main(){
n=read();
for(int i=1,x;i<=n;i++){
x=read();
ans^=x;
}
cout<<ans<<endl;
return 0;
}
#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
#include <fcntl.h>
#include <sys/mman.h>
#include <sys/stat.h>
#include <unistd.h>
char *pc;
int rd(){
int x=0,f=1;
char c=*pc++;
while(!isdigit(c)){
if(c=='-') f=-1;
c=*pc++;
}
while(isdigit(c)) x=x*10+c-'0',c=*pc++;
return x*f;
}
int main(){
int fd=0;
struct stat state;
fstat(fd,&state);
pc=(char*)mmap(NULL,state.st_size,PROT_READ,MAP_PRIVATE,fd,0);
close(fd);
n=rd();
for(int i=1,x;i<=n;i++){
x=rd();
ans^=x;
}
cout<<ans<<endl;
return 0;
}
12 号选手
#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
int read(){
int num=0,f=1;char c=getchar_unlocked();
while(c<'0'||c>'9'){if(c=='-')f=-1;c=getchar_unlocked();}
while(c>='0'&&c<='9'){num=num*10+(c-'0');c=getchar_unlocked();}
return num*f;
}
int main(){
n=read();
for(int i=1,x;i<=n;i++){
x=read();
ans^=x;
}
cout<<ans<<endl;
return 0;
}
13 号选手
#include<bits/stdc++.h>
using namespace std;
int n;
int ans;
#define MAXSIZE (1<<20)
#define isdigit(x) ( x >= '0' && x <= '9' )
#define blank(x) ( x == ' ' || x == '\n' || x == '\r' || x == '\t' )
#define Setprecision 6
namespace Fread {
char buf[MAXSIZE] ,*p1,*p2 ;//输入缓冲区优化(Fread命名空间)
inline char getchar () { if (p1 == p2) p2 = (p1 = buf) + fread(buf , 1 , MAXSIZE , stdin) ; return p1 == p2 ? '\n' : *p1++ ; }//定义getchar()
}
namespace Fwrite {//输出缓冲区优化(Fwrite命名空间)
char buf[MAXSIZE],*p1 = buf , *p2 = buf + MAXSIZE ;
inline void flush () { fwrite(buf, 1, p1 - buf, stdout); p1 = buf; }
inline void putchar (char c) { *p1++ = c; if (p1 == p2) flush(); }//定义putchar()
struct NTR { ~NTR() { flush(); } } ztr;// 程序结束时自动刷新
}
using namespace Fread ;
using namespace Fwrite ;
#define getchar Fread::getchar
#define putchar Fwrite::putchar
namespace IO
{
struct Reader //Reader类(重载>>运算符)
{
template <typename T> Reader& operator >> (T &x) //int ,long long ,long ,__int128
{
x = 0 ; short f = 1 ;char c = getchar() ;
while ( !isdigit(c) ) {if (c == '-') { f = -1 ; } c = getchar() ; }
while ( isdigit(c) ) x = (x << 3) + (x << 1) + (c ^ 48) , c = getchar() ;
x *= f ;
return *this ;
}
Reader& operator >> (double &x)//double
{
x = 0 ; double t = 0 ; short f = 1 , s = 0 ; char c = getchar() ;
while ( (!isdigit(c)) && c != '.' ) {if (c == '-') { f = -1 ; } c = getchar() ; }
while ( (isdigit(c)) && c != '.' ) x = (x * 10) + (c ^ 48) , c = getchar() ;
if (c == '.') c = getchar() ;
else { x *= f ; return *this ; }
while (isdigit(c)) t = t * 10 + (c ^ 48) , s++ , c = getchar() ;
while (s--) t /= 10.0 ;
x = (x + t) * f ;
return *this ;
}
Reader& operator >> (long double &x)//long double
{
x = 0 ; long double t = 0 ; short f = 1 , s = 0 ; char c = getchar() ;
while ( (!isdigit(c)) && c != '.') { if (c == '-') { f = -1 ; } c = getchar() ; }
while ( (isdigit(c)) && c != '.' ) x = (x * 10) + (c ^ 48) , c = getchar() ;
if (c == '.') c = getchar() ;
else { x *= f ; return *this ; }
while (isdigit(c)) t = t * 10 + (c ^ 48) , s++ , c = getchar() ;
while (s--) t /= 10.0 ;
x = (x + t) * f ;
return *this ;
}
Reader& operator >> (__float128 &x)//__float128
{
x = 0 ; __float128 t = 0 ; short f = 1 , s = 0 ; char c = getchar() ;
while ( (!isdigit(c)) && c != '.') { if (c == '-') { f = -1 ; } c = getchar() ; }
while ( (isdigit(c)) && c != '.' ) x = (x * 10) + (c ^ 48) , c = getchar() ;
if (c == '.') c = getchar() ;
else { x *= f ; return *this ; }
while (isdigit(c)) t = t * 10 + (c ^ 48) , s++ , c = getchar() ;
while (s--) t /= 10.0 ;
x = (x + t) * f ;
return *this ;
}
Reader& operator >> (char &c)//char
{
c = getchar() ;
while ( blank(c) ) c = getchar() ;
return *this ;
}
Reader& operator >> (char *str)//char[]
{
int len = 0;
char c = getchar() ;
while ( blank(c) ) c = getchar() ;
while ( !blank(c) ) str[len++] = c , c = getchar() ;
str[len] = '\0' ;
return *this ;
}
Reader& operator >> (string &str)//string
{
str.clear() ;
char c = getchar() ;
while ( blank(c) ) c = getchar() ;
while ( !blank(c) ) str.push_back(c) , c = getchar() ;
return *this ;
}
Reader() {}
}cin;
const char endl = '\n' ;//endl -> '\n'
struct Writer//Writer类(重载<<运算符)
{
typedef int mxdouble ;
template <typename T> Writer& operator << (T x)//int ,long long ,long ,__int128
{
if (x == 0) { putchar('0') ; return *this; }
if (x < 0) putchar('-') , x = -x ;
static short sta[40] ;
short top = 0 ;
while (x > 0) sta[++top] = x % 10 , x /= 10 ;
while (top > 0) putchar(sta[top] + '0') , top-- ;
return *this ;
}
Writer& operator << (double x)//double
{
if (x < 0) putchar('-') , x = -x ;
mxdouble _ = x;
x -= (double)_;
static short sta[40] ;
short top = 0 ;
while (_ > 0) sta[++top] = _ % 10 , _ /= 10 ;
if (top == 0) putchar('0') ;
while (top > 0) putchar(sta[top] + '0'), top-- ;
putchar('.') ;
for (int i = 0 ; i < Setprecision; i++) x *= 10 ;
_ = x;
while (_ > 0) sta[++top] = _ % 10 , _ /= 10 ;
for (int i = 0 ; i < Setprecision - top ; i++) putchar('0') ;
while (top > 0) putchar(sta[top] + '0') , top-- ;
return *this ;
}
Writer& operator << (long double x)//long double
{
if (x < 0) putchar('-') , x = -x ;
mxdouble _ = x ;
x -= (long double)_ ;
static short sta[40] ;
short top = 0 ;
while (_ > 0) sta[++top] = _ % 10 , _ /= 10 ;
if (top == 0) putchar('0') ;
while (top > 0) putchar(sta[top] + '0') , top-- ;
putchar('.');
for (int i = 0 ; i < Setprecision ; i++) x *= 10 ;
_ = x ;
while (_ > 0) sta[++top] = _ % 10 , _ /= 10 ;
for (int i = 0 ; i < Setprecision - top ; i++) putchar('0') ;
while (top > 0) putchar(sta[top] + '0') , top-- ;
return *this ;
}
Writer& operator << (__float128 x)//__float128
{
if (x < 0) putchar('-') , x = -x ;
mxdouble _ = x ;
x -= (__float128)_ ;
static short sta[40] ;
short top = 0;
while (_ > 0) sta[++top] = _ % 10 , _ /= 10 ;
if (top == 0) putchar('0') ;
while (top > 0) putchar(sta[top] + '0'), top-- ;
putchar('.') ;
for (int i = 0 ; i < Setprecision ; i++) x *= 10 ;
_ = x;
while (_ > 0) sta[++top] = _ % 10 , _ /= 10 ;
for (int i = 0 ; i < Setprecision - top; i++) putchar('0') ;
while (top > 0) putchar(sta[top] + '0') , top-- ;
return *this ;
}
Writer& operator << (char c) { putchar(c) ; return *this ; }//char
Writer& operator << (char *str)//char[]
{
int cur = 0 ;
while (str[cur]) putchar(str[cur++]) ;
return *this ;
}
Writer& operator << (const char *str)
{
int cur = 0 ;
while (str[cur]) putchar(str[cur++]) ;
return *this ;
}
Writer& operator << (string str)//string
{
int st = 0, ed = str.size() ;
while (st < ed) putchar(str[st++]) ;
return *this ;
}
Writer() {}
}cout;
}
using namespace IO;
#define cin IO::cin
#define cout IO::cout
#define endl IO::endl
int main(){
cin>>n;
for(int i=1,x;i<=n;i++){
cin>>x;
ans^=x;
}
cout<<ans<<endl;
return 0;
}
14 号选手
#include<bits/stdc++.h>
#include<unistd.h>
using namespace std;
int n;
int ans;
char buffer[32769];
unsigned li=0;
int fastread(){
char ch;
do{
read(0,&ch,1);
} while(ch==' '||ch=='\n');
int flag=(ch!='-'?1:(read(0, &ch, 1)*0+-1));
int a=0;
do{
a=a*10+ch-'0';
read(0,&ch,1);
}while(ch>='0'&&ch<='9');
return a*flag;
}
int main(){
n=fastread();
for(int i=1,x;i<=n;i++){
x=fastread();
ans^=x;
}
cout<<ans<<endl;
return 0;
}
\color{white}总是有人问我,哎呀 CEXE \color{white}你为什么总是出毒瘤模拟赛?那我问你:\color{white}我不出模拟赛我会不会没事干?\color{white}我们不做模拟赛会不会保龄?\color{white}回答我!\color{white}Look in my eyes!\color{white}Tell me!\color{white}Why why baby why\color{white}没事干会不会就去颓?\color{white}嗯?\color{white}你回答我