Submission #570524

#TimeUsernameProblemLanguageResultExecution timeMemory
570524timreizinLamps (JOI19_lamps)C++17
4 / 100
7 ms4456 KiB
#include <iostream> #include <vector> #include <numeric> #include <cmath> #include <set> #include <array> #include <algorithm> using namespace std; using ll = long long; int main() { cin.tie(0)->sync_with_stdio(0); int n; string a, b; cin >> n >> a >> b; b.push_back('0'); int res = 0; for (int i = 1; i <= n; ++i) res += b[i] == '0' && b[i - 1] == '1'; cout << res; 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...