# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
637523 |
2022-09-02T11:17:22 Z |
NotLinux |
Cipele (COCI18_cipele) |
C++14 |
|
41 ms |
3680 KB |
/**
* author: NotLinux
* created: isoD
**/
#include <bits/stdc++.h>
using namespace std;
#define int long long
#ifdef LOCAL
#include "/home/notlinux/debug.h"
#else
#define debug(x...) void(37)
#endif
void solve(){
int n,m;cin >> n >> m;
vector < int > a(n),b(m);
for(auto &itr : a)cin >> itr;
for(auto &itr : b)cin >> itr;
sort(a.begin(),a.end());
sort(b.begin(),b.end());
int ans = 0;
for(int i = 0;i<n;i++){
ans = max(ans,abs(a[i]-b[i]));
}
cout << ans << endl;
}
int32_t main(){
ios_base::sync_with_stdio(0);cin.tie(nullptr);
int tt=1;
//cin >> tt;
while(tt--)solve();
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
19 ms |
3412 KB |
Output is correct |
2 |
Correct |
32 ms |
3668 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
34 ms |
3668 KB |
Output is correct |
2 |
Correct |
41 ms |
3680 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
340 KB |
Output is correct |
2 |
Correct |
2 ms |
468 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
1 ms |
340 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
1 ms |
340 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
1 ms |
340 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
2 ms |
340 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
28 ms |
3000 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
35 ms |
3300 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
26 ms |
2900 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |