이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <iostream>
#include <algorithm>
#include <vector>
#include <cstring>
#include <fstream>
#include <string>
#include <map>
#include <queue>
#include <utility>
#include <stack>
#include <cstdio>
#include <cmath>
#include <set>
using namespace std;
#define in cin
#define out cout
#define REP(i,n) for(int i=0; i<n; i++)
#define REP2(i,s,e) for(int i=s; i<e; i++)
#define REPE(i,s,e) for(int i=s; i<=e; i++)
#define REPR(i,s,e) for(int i=s; i>=e; i--)
#define all(v) v.begin(), v.end()
#define pb push_back
#define ll long long
#define pii pair<int, int>
#define x first
#define y second
#define intINF 2147483647
#define llINF 9223372036854775807LL
#define MOD 1000000007
int main()
{
int tc; in >> tc;
while(tc--)
{
ll x, y; in >> x >> y;
ll t = 1;
while(t <= x) t *= 10;
int r = 0;
while(t+x <= y)
{
t *= 10;
r++;
}
out << r << '\n';
}
return 0;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |