Submission #618108

#TimeUsernameProblemLanguageResultExecution timeMemory
618108rubdaryArranging Shoes (IOI19_shoes)C++14
0 / 100
0 ms212 KiB
#include "shoes.h" #include <iostream> #include <vector> using namespace std; long long count_swaps(vector<int> s){ int N = s.size(); vector <int> negativos; for(int i = 0; i < N; i++){ if(s[i] < 0) negativos.push_back(i); } int res = 0; for(int i = 0; i < N; i = i+2){ res += s[i/2] - i; } return res; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...