#include<bits/stdc++.h> using namespace std; int aa; int main(){ int n,one=0,two=0,three=0; cin>>n; for(int i=1;i<=n;i++){ cin>>aa; two^=(one&aa); one^=aa; three=~(one&two); two&=three; one&=three; } cout<<one; }
注册一个 TeMenHu 通用账户,您就可以在我们提供的所有在线评测服务上提交代码、参与讨论。
使用您的 TeMenHu 通用账户