# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
20548 | 후시기다네가후시기다네 (#35) | 채점 시스템 (OJUZ11_judge) | C++98 | 156 ms | 2020 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include<cstdio>
#include<iostream>
#include<string>
using namespace std;
int main(void)
{
int n; cin >> n;
char buff[100];
string a, b;
while (n--)
{
scanf("%s", buff);
a = buff;
scanf("%s", buff);
b = buff;
if (a.size() >= b.size())
{
cout << 0 << endl;
continue;
}
int cnt = b.size() - a.size() - 1;
for (int i = 0; i < cnt; i ++)
a.insert(0, 1, '0');
a.insert(0, 1, '1');
if (a > b)
cout << cnt << endl;
else
cout << cnt + 1 << endl;
}
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |