| # | Time | Username | Problem | Language | Result | Execution time | Memory |
|---|---|---|---|---|---|---|---|
| 832378 | Liudas | Crosses on the Grid (FXCUP4_cross) | C++17 | 51 ms | 10352 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 <iostream>
#include <vector>
#include <set>
#include <algorithm>
using namespace std;
struct cross{
int i, o;
long long s;
};
long long SelectCross(int K, vector<int> I, vector<int> O){
int N = I.size();
vector<cross> arr(N);
for(int i = 0; i < N; i++){
arr[i] = {I[i], O[i], 1ll * I[i] * O[i] * 2 - 1ll * I[i] * I[i]};
}
sort(arr.begin(), arr.end(), [](cross a, cross b){return a.s < b.s;});
return arr.back().s;
}| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
