(UPD: 2024-12-04 14:48 UTC) Judge is not working due to Cloudflare incident. (URL) We can do nothing about it, sorry. After the incident is resolved, we will grade all submissions.

제출 #537775

#제출 시각아이디문제언어결과실행 시간메모리
537775zaneyuHop (COCI21_hop)C++14
110 / 110
20 ms1328 KiB
/*input 8 3 4 6 9 12 18 36 72 */ #include<bits/stdc++.h> using namespace std; #define REP(i,n) for(int i=0;i<n;i++) #define MNTO(x,y) x=min(x,y) #define MXTO(x,y) x=max(x,y) #define REP1(i,n) for(int i=1;i<=n;i++) #define ll long long #define ld long double #define sz(x) (int)x.size() #define pii pair<int,int> #define f first #define s second #define pb push_back const int maxn=1e5+5; ll arr[maxn]; int main(){ ios::sync_with_stdio(false),cin.tie(0); int n; cin>>n; REP(i,n) cin>>arr[i]; REP(i,n){ REP(j,i){ int a=__lg(arr[i]),b=__lg(arr[j]); if(a/4==b/4) cout<<"2 "; else if(a/16==b/16) cout<<"1 "; else cout<<"3 "; } cout<<'\n'; } }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...