# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
62644 | win11905 | Tuna (COCI17_tuna) | C++11 | 4 ms | 640 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, m, sum = 0; cin >> n >> m;
while(n--) {
int a, b; cin >> a >> b;
if(a < b) swap(a, b);
if(a - b <= m) sum += a;
else sum += *istream_iterator<int>(cin);
}
printf("%d\n", sum);
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |