QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#412850 | #6749. Target | XiaoretaW | WA | 0ms | 3736kb | C++20 | 493b | 2024-05-16 20:20:54 | 2024-05-16 20:20:54 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
#define ll long long
const double eps = 1e-4 - 1e-6;
int main() {
ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);
double a, b; cin >> a >> b;
string ans = "";
for (int i = 0; i < 50; i++) {
if (b - 1 >= 0) {
b -= 1;
cout << 2;
} else cout << 1;
b *= 2;
}
reverse(ans.begin(), ans.end());
cout << ans << '\n';
return 0;
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 0
Wrong Answer
time: 0ms
memory: 3736kb
input:
0.5 0.25
output:
11211111111111111111111111111111111111111111111111
result:
wrong answer wa