# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
738260 | 2023-05-08T10:39:23 Z | MrAndria | Table Tennis (info1cup20_tabletennis) | C++14 | 3000 ms | 3136 KB |
#include <bits/stdc++.h> using namespace std; #define pb push_back #define ff first #define ss second long long n,k,sum,ans,a[1000005]; vector <long long> v; map <long long,long long> mp; int main(){ ios::sync_with_stdio(false); cin.tie(NULL); cin>>n>>k; for(int i=1;i<=n+k;i++){ cin>>a[i]; sum+=a[i]; } if(k==1){ for(int i=1;i<=n+k;i++){ mp.clear(); for(int j=1;j<=n+k;j++){ mp[a[j]]++; } ans=0; mp[a[i]]--; for(int j=1;j<=n+k;j++){ if(j!=i){ if(mp[((sum-a[i])/(n/2))-a[j]]>=1 and mp[a[j]]>=1){ mp[((sum-a[i])/(n/2))-a[j]]--; ans++; mp[a[j]]--; } } } if(ans==(n/2)){ for(int j=1;j<=n;j++){ if(j!=i){ v.pb(a[j]); } } sort(v.begin(),v.end()); for(int i=0;i<v.size();i++){ cout<<v[i]<<" "; } cout<<endl; return 0; } } } // for(int i=1;i<=n+k;i++){ // for(int j=1;j<=n+k;j++){ // // } // } } /* ########################### ########################## ################################ ##################################### #################### ############################################## ############################### ############################### ################################## ##################################### #################### ################################################## ################################# ################################# #################################### ##################################### #################### ###################################################### ################################### ################################### ###################################### ##################################### #################### ######################################################### ############ ######### ######## ############ ######################################## ##################################### #################### ############### ############ ######### ######## ############ ############ ############ ##################################### #################### ############### ############ ######### ######## ############ ############ ############ ################# #################### ############### ############ ######### ######## ############ ############ ############ ################# #################### ############### ############ #################### ############ ############ ############ ################# ############### ############ ################# ############ ############ ############ ################# #################### ############### ############ ############## ############ ############ ############ ################# #################### ############### ############ ############ ############ ############ ############ ################# #################### ############### ############ ########## ############ ############ ############ ##################################### #################### ############### ############ ###### ############ ############ ############ ##################################### #################### ############### ############ #### ############ ############################################################ ##################################### #################### ############### ###################### ############ ############ ############################################################## ##################################### #################### ############### ###################### ############ ############ ################################################################ ##################################### #################### ############### ############ ############ ############ ############ ############ ##################################### #################### ############### ############ ############ ############ ############ ############ ##################### #################### ############### ############ ############ ############ ############ ############ ##################### #################### ############### ############ ############ ############ ############ ############ ##################### #################### ############### ############ ############ ############ ############ ############ ##################### #################### ############### ############ ############ ############ ############ ############ ##################### #################### ############### ############ ############ ############ ############ ############ ##################### #################### ############### ############ ############ ############ ############ ############ ##################################### #################### ######################################################## ############ ############ ############ ############ ##################################### #################### ####################################################### ############ ############ ############ ############ ##################################### #################### ##################################################### ############ ############ ############ ############ ##################################### #################### ################################################# ############ ############ ############ ############ */
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 468 KB | Unexpected end of file - int32 expected |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Execution timed out | 3042 ms | 3136 KB | Time limit exceeded |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 14 ms | 2876 KB | Unexpected end of file - int32 expected |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 0 ms | 212 KB | Unexpected end of file - int32 expected |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 1 ms | 212 KB | Unexpected end of file - int32 expected |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 1 ms | 212 KB | Unexpected end of file - int32 expected |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 1 ms | 212 KB | Unexpected end of file - int32 expected |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 1 ms | 212 KB | Unexpected end of file - int32 expected |
2 | Halted | 0 ms | 0 KB | - |