Run ID Author Problem Lang Verdict Time Memory Code Length Submit Time
52404 teacher_lu 连续数字 C++ Accepted 1 MS 248 KB 407 2024-10-05 12:14:05

Tests(20/20):


#include <bits/stdc++.h> using namespace std; int n, m; int main() { cin >> n >> m; for (int i = 1; i <= n; i++) { if (m > 0) { if (i % 3 == 1 || i % 3 == 2) { cout << 1; m--; } else cout << 0; } else cout << 0; } return 0; }


Judgement Protocol: