Submission #938523

#TimeUsernameProblemLanguageResultExecution timeMemory
938523LucaIlieBoarding Passes (BOI22_passes)C++17
0 / 100
1 ms348 KiB
#include <bits/stdc++.h> using namespace std; double expectedInversions( int n ) { return (double)n * (n - 1) / 4; } int main() { int n; string s; // cin >> s; n = s.size(); cin >> n; cout << fixed << setprecision( 3 ) << expectedInversions( n / 2 ) + expectedInversions( n - n / 2 ); return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...