Submission #999983

#TimeUsernameProblemLanguageResultExecution timeMemory
999983pudelosBoarding Passes (BOI22_passes)C++17
0 / 100
1 ms600 KiB
#include <bits/stdc++.h> using namespace std; #define FOR(i, a, b) for(int i=a; i<=b; ++i) #define ll long long #define ld long double int main() { cin.tie(0) -> ios_base::sync_with_stdio(0); string s; cin >> s; int n = s.size(); int l = n/2; int r = n/2+n%2; ll sum = l*(l-1) + r*(r-1); ld w = (ld)(sum)/4; cout << fixed << setprecision(15) << w << '\n'; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...