# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
73336 |
2018-08-28T07:35:59 Z |
노영훈(#2269) |
Radio (Balkan15_RADIO) |
C++11 |
|
33 ms |
776 KB |
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int MX=100010;
int n, X[MX], P[MX], S[MX];
ll ans;
int main(){
ios::sync_with_stdio(0); cin.tie(0);
cin>>n;
for(int i=1; i<=n; i++) cin>>X[i]>>P[i]>>S[i];
for(int i=1; i<=n; i++){
for(int j=i+1; j<=n; j++){
int x=max(0, X[j]-X[i]-P[j]);
ans+=x; P[i]+=x;
}
}
cout<<ans<<'\n';
return 0;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
3 ms |
376 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
5 ms |
448 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
4 ms |
448 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
30 ms |
600 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
33 ms |
776 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
3 ms |
776 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |