diff --git a/CPP/Alice_vs_Bob_Faceoff.cpp b/CPP/Alice_vs_Bob_Faceoff.cpp new file mode 100644 index 0000000..a293747 --- /dev/null +++ b/CPP/Alice_vs_Bob_Faceoff.cpp @@ -0,0 +1,106 @@ +#pragma GCC optimize ("trapv") +#include +#include +#include +#include +#include +#include +#include +#include +#include +using namespace std; +#define pb push_back +#define all(v) v.begin(),v.end() +#define rep(i,n,v) for(i=n;iv;i--) +#define ff first +#define ss second +#define pp pair +#define ll long long +#define ld long double +#define endl "\n" + +const ll mod=1e9+7; +void solve() +{ +ll n, a=0,b=0,m=1, c=-1,k=0, i=0, j=0, l=1e9+5; +string s,p, q; + // mapmp; + // mp[1]=0; + // mp[2]=1; + // rep(i,3,1e5+1){ + // if(i%2) { + // if(mp[i-1]==0) mp[i]=1; + // else mp[i]=0; + // } + // else{ + // a=2;j=0; + // while(a<=i){ + // if(i%a==0 && mp[i/a]==1){ + // j=1;mp[i]=0;break; + // } + // a*=2; + // } + // if(!j) mp[i]=1; + // } + // } + +cin>>a; +rep(i,0,a){ + cin>>n; + if(n==1) cout<<"Alice"<=2) b++; + } + if(b>=2) cout<<"Bob"<=2) b++; + } + if(b>=2) cout<<"Alice"<>t; +while(t--) +{ +solve(); +} +return 0; +} \ No newline at end of file