Submission #143771

#TimeUsernameProblemLanguageResultExecution timeMemory
143771jwvg0425Arranging Shoes (IOI19_shoes)C++17
10 / 100
30 ms1904 KiB
#include "shoes.h" long long count_swaps(std::vector<int> s) { long long ans = 0; for (int i = 0; i < s.size(); i += 2) { if (s[i + 1] < 0) ans++; } return ans; }

Compilation message (stderr)

shoes.cpp: In function 'long long int count_swaps(std::vector<int>)':
shoes.cpp:5:23: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     for (int i = 0; i < s.size(); i += 2)
                     ~~^~~~~~~~~~
#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...