QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#536054#8651. Table Tennislfyszy100 ✓171ms50808kbC++144.4kb2024-08-28 18:04:322024-08-28 18:04:32

Judging History

你现在查看的是最新测评结果

  • [2024-08-28 18:04:32]
  • 评测
  • 测评结果:100
  • 用时:171ms
  • 内存:50808kb
  • [2024-08-28 18:04:32]
  • 提交

answer

// O(N^2) steps, each in O(1)

#include <cassert>
#include <cmath>
#include <cstdint>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <functional>
#include <iostream>
#include <limits>
#include <map>
#include <numeric>
#include <queue>
#include <random>
#include <set>
#include <sstream>
#include <string>
#include <unordered_map>
#include <unordered_set>
#include <utility>
#include <vector>

using namespace std;

using Int = long long;

template <class T1, class T2> ostream &operator<<(ostream &os, const pair<T1, T2> &a) { return os << "(" << a.first << ", " << a.second << ")"; };
template <class T> ostream &operator<<(ostream &os, const vector<T> &as) { const int sz = as.size(); os << "["; for (int i = 0; i < sz; ++i) { if (i >= 256) { os << ", ..."; break; } if (i > 0) { os << ", "; } os << as[i]; } return os << "]"; }
template <class T> void pv(T a, T b) { for (T i = a; i != b; ++i) cerr << *i << " "; cerr << endl; }
template <class T> bool chmin(T &t, const T &f) { if (t > f) { t = f; return true; } return false; }
template <class T> bool chmax(T &t, const T &f) { if (t < f) { t = f; return true; } return false; }
#define COLOR(s) ("\x1b[" s "m")


Int c2(Int n) {
  return n*(n-1)/2;
}
Int c3(Int n) {
  return n*(n-1)*(n-2)/6;
}
Int minK(Int n) {
  return (n & 1) ? (n * c2(n/2)) : ((n/2) * c2(n/2 - 1) + (n/2) * c2(n/2));
}

vector<string> solveMin(int N) {
  if (N & 1) {
    vector<string> a(N, string(N, '0'));
    for (int u = 0; u < N; ++u) {
      int v = u;
      for (int i = 1; i <= N/2; ++i) {
        if (++v == N) v = 0;
        a[u][v] = '1';
      }
    }
    return a;
  } else {
    auto a = solveMin(N + 1);
    a.pop_back();
    for (int u = 0; u < N; ++u) a[u].pop_back();
    return a;
  }
}

vector<string> solve(int N, Int K) {
  if (!(minK(N) <= K && K <= c3(N))) return {};
  
  Int k;
  vector<string> a;
  {
    Int sum = 0;
    int n = N;
    for (; n && minK(n) + c2(n-1) + sum <= K; --n) sum += c2(n-1);
    k = minK(n) + sum;
    a = solveMin(n);
    for (int u = 0; u < n; ++u) a[u].resize(N, '0');
    a.resize(N, string(N, '0'));
    for (int u = n; u < N; ++u) for (int v = 0; v < u; ++v) a[u][v] = '1';
  }
  
  vector<vector<int>> uss(N);
  for (int u = 0; u < N; ++u) {
    int d = 0;
    for (int v = 0; v < N; ++v) if (a[u][v] == '1') ++d;
    uss[d].push_back(u);
  }
  vector<int> inq(N + 1, 0);
  queue<int> que;
  for (int d = 0; d < N; ++d) if (uss[d].size() >= 2) {
    inq[d] = 1;
    que.push(d);
  }
  for (; k < K; ++k) {
    const int d = que.front();
    que.pop();
    inq[d] = 0;
    int u = uss[d].back(); uss[d].pop_back();
    int v = uss[d].back(); uss[d].pop_back();
    swap(a[u][v], a[v][u]);
    if (a[u][v] == '1') swap(u, v);
    uss[d - 1].push_back(u);
    uss[d + 1].push_back(v);
    for (int dd = d - 1; dd <= d + 1; ++dd) if (uss[dd].size() >= 2) {
      if (!inq[dd]) {
        inq[dd] = 1;
        que.push(dd);
      }
    }
  }
  return a;
}

void stress() {
  for (int N = 0; N <= 30; ++N) {
    cerr << "N = " << N << ": " << minK(N) << " <= K <= " << c3(N) << endl;
    for (Int K = 0; K <= c3(N); ++K) {
      const auto adj = solve(N, K);
      if (minK(N) <= K && K <= c3(N)) {
        assert((int)adj.size() == N);
        for (int u = 0; u < N; ++u) for (int v = 0; v < N; ++v) assert(adj[u][v] == '0' || adj[u][v] == '1');
        for (int u = 0; u < N; ++u) assert(adj[u][u] == '0');
        for (int u = 0; u < N; ++u) for (int v = 0; v < N; ++v) if (u != v) assert(adj[u][v] != adj[v][u]);
        Int score = 0;
        for (int u = 0; u < N; ++u) for (int v = 0; v < N; ++v) for (int w = 0; w < N; ++w) {
          if (adj[u][v] == '1' && adj[u][w] == '1' && adj[v][w] == '1') ++score;
        }
        assert(score == K);
      } else {
        assert(!adj.size());
      }
    }
  }
}

int main() {
  // stress(); return 0;
  
  for (int numCases; ~scanf("%d", &numCases); ) for (int caseId = 1; caseId <= numCases; ++caseId) {
    int N;
    Int K;
    scanf("%d%lld", &N, &K);
    K = c3(N) - K;
    
    const auto adj = solve(N, K);
    if (adj.size()) {
      puts("Yes");
      for (int u = 1; u < N; ++u) {
        puts(adj[u].substr(0, u).c_str());
      }
    } else {
      puts("No");
    }
  }
  return 0;
}

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 5
Accepted

Test #1:

score: 5
Accepted
time: 1ms
memory: 3728kb

input:

97
3 0
4 0
5 0
6 0
7 0
8 0
9 0
10 0
11 0
12 0
13 0
14 0
15 0
16 0
17 0
18 0
19 0
20 0
21 0
22 0
23 0
24 0
25 0
26 0
27 0
28 0
29 0
30 0
31 0
32 0
33 0
34 0
35 0
36 0
37 0
38 0
39 0
40 0
41 0
42 0
43 0
44 0
45 0
46 0
47 0
48 0
49 0
50 0
51 0
52 0
53 0
54 0
55 0
56 0
57 0
58 0
59 0
60 0
61 0
62 0
63 0...

output:

Yes
1
11
Yes
0
00
111
Yes
0
01
111
1111
Yes
0
00
011
1111
11111
Yes
0
01
011
1111
11111
111100
Yes
0
00
011
0111
11111
111111
1111110
Yes
0
00
011
0111
11111
111111
1111110
11111111
Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
11...

result:

ok good job! (97 test cases)

Test #2:

score: 5
Accepted
time: 16ms
memory: 26860kb

input:

5
4839 0
127 0
22 0
7 0
5 0

output:

Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (5 test cases)

Test #3:

score: 5
Accepted
time: 8ms
memory: 5992kb

input:

11
1191 0
1580 0
199 0
484 0
209 0
1226 0
92 0
5 0
4 0
4 0
6 0

output:

Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (11 test cases)

Test #4:

score: 5
Accepted
time: 3ms
memory: 6968kb

input:

8
953 0
1747 0
1782 0
213 0
210 0
82 0
10 0
3 0

output:

Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (8 test cases)

Test #5:

score: 5
Accepted
time: 0ms
memory: 3868kb

input:

1
6 0

output:

Yes
0
00
011
1111
11111

result:

ok good job! (1 test case)

Test #6:

score: 5
Accepted
time: 0ms
memory: 3964kb

input:

1
7 0

output:

Yes
0
01
011
1111
11111
111100

result:

ok good job! (1 test case)

Test #7:

score: 5
Accepted
time: 0ms
memory: 3712kb

input:

1
19 0

output:

Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #8:

score: 5
Accepted
time: 0ms
memory: 3668kb

input:

1
20 0

output:

Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #9:

score: 5
Accepted
time: 0ms
memory: 3748kb

input:

1
149 0

output:

Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #10:

score: 5
Accepted
time: 0ms
memory: 3632kb

input:

1
150 0

output:

Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #11:

score: 5
Accepted
time: 1ms
memory: 4352kb

input:

1
599 0

output:

Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #12:

score: 5
Accepted
time: 1ms
memory: 4100kb

input:

1
600 0

output:

Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #13:

score: 5
Accepted
time: 19ms
memory: 28684kb

input:

1
4999 0

output:

Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #14:

score: 5
Accepted
time: 15ms
memory: 28492kb

input:

1
5000 0

output:

Yes
0
00
011
0111
11111
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #15:

score: 5
Accepted
time: 1ms
memory: 3604kb

input:

291
3 0
3 1
4 0
4 1
4 2
5 0
5 1
5 2
5 3
6 0
6 1
6 2
6 3
6 4
7 0
7 1
7 2
7 3
7 4
7 5
8 0
8 1
8 2
8 3
8 4
8 5
8 6
9 0
9 1
9 2
9 3
9 4
9 5
9 6
9 7
10 0
10 1
10 2
10 3
10 4
10 5
10 6
10 7
10 8
11 0
11 1
11 2
11 3
11 4
11 5
11 6
11 7
11 8
11 9
12 0
12 1
12 2
12 3
12 4
12 5
12 6
12 7
12 8
12 9
12 10
13 0
...

output:

Yes
1
11
Yes
0
10
Yes
0
00
111
Yes
0
00
101
Yes
0
00
100
Yes
0
01
111
1111
Yes
0
01
110
1111
Yes
0
01
110
1101
Yes
0
01
100
1101
Yes
0
00
011
1111
11111
Yes
0
00
011
1110
11111
Yes
0
00
011
1010
11111
Yes
0
00
011
1010
11101
Yes
0
00
011
1000
11101
Yes
0
01
011
1111
11111
111100
Yes
0
01
011
1111
11...

result:

ok good job! (291 test cases)

Test #16:

score: 5
Accepted
time: 8ms
memory: 6312kb

input:

11
123 75
1445 897
1645 84
577 115
634 455
118 80
411 132
18 8
23 8
3 1
3 1

output:

Yes
0
01
010
0101
01111
010100
0001101
00000000
110101110
1111011110
11011000100
111111110011
1111111101110
10000000000000
111111110000001
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (11 test cases)

Test #17:

score: 5
Accepted
time: 13ms
memory: 9620kb

input:

7
1948 1328
2367 1910
216 211
374 276
36 32
20 8
39 6

output:

Yes
0
00
000
0000
00000
000000
0000000
00000011
000000010
0000000000
00000001111
000000010111
0000000101111
00000000001111
000000000010000
0000000011011101
00000011011111011
100000000111000101
1100000111101101101
11100011100001001111
111100000001101101100
1111101100111011101101
111111001100111101111...

result:

ok good job! (7 test cases)

Test #18:

score: 5
Accepted
time: 7ms
memory: 13100kb

input:

6
3051 778
750 222
966 939
138 126
90 28
4 0

output:

Yes
0
00
000
0001
00010
000010
0000001
00011111
000010110
0001011000
00000000000
000100110011
0010111101011
00010111000110
000000000000000
1000000000000000
11100101010010000
111100101110110001
1111100100011000010
11111100011111100011
110001110001001000000
1111111111011110000111
111111111010011000000...

result:

ok good job! (6 test cases)

Test #19:

score: 5
Accepted
time: 0ms
memory: 3676kb

input:

1
6 0

output:

Yes
0
00
011
1111
11111

result:

ok good job! (1 test case)

Test #20:

score: 5
Accepted
time: 0ms
memory: 3680kb

input:

1
7 2

output:

Yes
0
01
011
1111
11111
111010

result:

ok good job! (1 test case)

Test #21:

score: 5
Accepted
time: 0ms
memory: 3656kb

input:

1
19 7

output:

Yes
0
01
011
0111
01100
111111
1111101
11111111
111110000
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #22:

score: 5
Accepted
time: 0ms
memory: 3656kb

input:

1
20 14

output:

Yes
0
00
000
0011
00110
110111
1111011
11111100
111111101
1011000000
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #23:

score: 5
Accepted
time: 0ms
memory: 3712kb

input:

1
149 6

output:

Yes
0
01
011
0111
01101
111111
1111101
11111111
111110000
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #24:

score: 5
Accepted
time: 0ms
memory: 3972kb

input:

1
150 44

output:

Yes
0
01
001
0011
00000
011101
0010011
11101111
111110100
1111111011
11111110110
100000000000
1111111000001
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #25:

score: 5
Accepted
time: 0ms
memory: 4040kb

input:

1
599 503

output:

Yes
0
00
001
0001
00000
000101
0000010
00011111
000000000
0001110111
00101111111
000101001110
0000101111000
10000000000010
101101110110001
1111111111100011
11110000111111010
111110001111111011
1111111100101111010
11111110001011110101
111111110101110011111
1111111110000011100100
111111111100001111011...

result:

ok good job! (1 test case)

Test #26:

score: 5
Accepted
time: 1ms
memory: 4128kb

input:

1
600 218

output:

Yes
0
00
011
0000
00000
000000
0000010
01101110
001011100
0001111111
10111011110
110101111100
1111111010101
11110110011011
111010000000100
1111110011100100
11111110100000011
111111110101110111
1110111000000000000
11111111110000000001
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #27:

score: 5
Accepted
time: 19ms
memory: 28388kb

input:

1
4999 4407

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000001
0000000000000011
00000000000001111
000000000000001110
0000000000000011000
00000000000001111111
000000000000111111111
0000000000110111111101
000000000000000111111...

result:

ok good job! (1 test case)

Test #28:

score: 5
Accepted
time: 15ms
memory: 28344kb

input:

1
4999 1436

output:

Yes
0
00
000
0000
00001
000000
0001101
00011110
000110110
0000001000
00000011011
000011111111
0001001100101
00011011001001
000000100000010
0000010101010111
00010111000101110
000000000000000000
1000000000000000000
11000000000000000000
111000000010001000000
1111100001110100110001
111111000011000110000...

result:

ok good job! (1 test case)

Test #29:

score: 5
Accepted
time: 15ms
memory: 28768kb

input:

1
5000 107

output:

Yes
0
01
011
0100
00000
010000
0100111
01001101
001010110
1110011011
11101001110
111010111111
1110111001111
11101111101111
111011111010111
1100000000000000
11111111100000001
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #30:

score: 5
Accepted
time: 15ms
memory: 28496kb

input:

1
5000 1509

output:

Yes
0
00
000
0000
00000
000000
0000001
00000000
000000000
0000000001
00000001111
000011011111
0000000001000
00000000111001
000000011111011
0000001000111111
00000011110101111
000011010011011100
1000010111010111011
11001101101101110010
111000010111101101101
1111001011100001111011
111110010000011111011...

result:

ok good job! (1 test case)

Test #31:

score: 5
Accepted
time: 17ms
memory: 28524kb

input:

1
5000 2242

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000011
000000001100111
0000000000001110
00000000000000000
000000000000111001
0000000011001111111
00000000001100111111
100000000011110011101
1100000000000010011000
111000000000110111110...

result:

ok good job! (1 test case)

Test #32:

score: 5
Accepted
time: 0ms
memory: 3676kb

input:

1
4 2

output:

Yes
0
00
100

result:

ok good job! (1 test case)

Test #33:

score: 5
Accepted
time: 0ms
memory: 3932kb

input:

1
5 3

output:

Yes
0
01
100
1101

result:

ok good job! (1 test case)

Test #34:

score: 5
Accepted
time: 0ms
memory: 3600kb

input:

1
6 4

output:

Yes
0
00
011
1000
11101

result:

ok good job! (1 test case)

Test #35:

score: 5
Accepted
time: 0ms
memory: 3656kb

input:

1
7 5

output:

Yes
0
01
010
1101
11111
111011

result:

ok good job! (1 test case)

Test #36:

score: 5
Accepted
time: 0ms
memory: 3616kb

input:

1
19 17

output:

Yes
0
00
001
0011
00000
010111
1010110
11111101
111111010
1111111101
11111100000
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #37:

score: 5
Accepted
time: 0ms
memory: 3948kb

input:

1
20 18

output:

Yes
0
00
001
0011
00100
010111
1010110
11111101
111111010
1111111101
11111100000
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #38:

score: 5
Accepted
time: 0ms
memory: 3640kb

input:

1
149 147

output:

Yes
0
00
001
0000
01010
001010
0011101
00111011
011011111
1000101101
11111010111
111110011011
1010001000100
11111011100100
111111001111011
1111111101110111
10101001000000000
111111111000000001
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #39:

score: 5
Accepted
time: 0ms
memory: 3684kb

input:

1
150 148

output:

Yes
0
00
001
0000
01010
001010
0011101
00111111
011011111
1000101101
11111010111
111110011011
1010001000100
11111011100100
111111001111011
1111111101110111
10101001000000000
111111111000000001
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #40:

score: 5
Accepted
time: 1ms
memory: 4092kb

input:

1
599 597

output:

Yes
0
00
001
0110
00110
001001
0011111
00010110
001011000
0000000000
00100110011
000100000010
0010010000101
00000000000000
110010101001000
1110010011010000
11110010001110010
111110000111100000
1100111000100100000
11111111101111000111
111111110100110000000
1111111111111100011110
111111101111010010110...

result:

ok good job! (1 test case)

Test #41:

score: 5
Accepted
time: 1ms
memory: 4136kb

input:

1
600 598

output:

Yes
0
00
001
0110
00110
001001
0011111
00010110
001011000
0000000000
00100110011
000100000010
0010010000101
00000000000000
110010101001000
1110010011010000
11110010001110010
111110000111100000
1100111000100100000
11111110101111000111
111111110100110000000
1111111111111100011110
111111101111010010110...

result:

ok good job! (1 test case)

Test #42:

score: 5
Accepted
time: 22ms
memory: 28676kb

input:

1
4999 4997

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000001
0000000000000010
00000000000000101
000000000000001111
0000000000000010100
00000000000000111111
000000000000001111010
0000000000000011111101
000000000000111111110...

result:

ok good job! (1 test case)

Test #43:

score: 5
Accepted
time: 27ms
memory: 28784kb

input:

1
5000 4998

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000001
0000000000000010
00000000000000101
000000000000001111
0000000000000010100
00000000000000111111
000000000000001011010
0000000000000011111101
000000000000111111110...

result:

ok good job! (1 test case)

Test #44:

score: 5
Accepted
time: 0ms
memory: 3656kb

input:

1
4 0

output:

Yes
0
00
111

result:

ok good job! (1 test case)

Test #45:

score: 5
Accepted
time: 0ms
memory: 3648kb

input:

1
5 1

output:

Yes
0
01
110
1111

result:

ok good job! (1 test case)

Test #46:

score: 5
Accepted
time: 0ms
memory: 3604kb

input:

1
6 1

output:

Yes
0
00
011
1110
11111

result:

ok good job! (1 test case)

Test #47:

score: 5
Accepted
time: 0ms
memory: 3708kb

input:

1
7 1

output:

Yes
0
01
011
1111
11111
111000

result:

ok good job! (1 test case)

Test #48:

score: 5
Accepted
time: 0ms
memory: 3612kb

input:

1
19 12

output:

Yes
0
00
000
0111
00110
110111
1111011
11111100
111111101
1011010000
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #49:

score: 5
Accepted
time: 0ms
memory: 3672kb

input:

1
20 13

output:

Yes
0
00
000
0011
00110
110111
1111011
11111100
111111101
1011010000
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #50:

score: 5
Accepted
time: 0ms
memory: 3752kb

input:

1
149 146

output:

Yes
0
00
001
0000
01010
001010
0011101
00111011
011011111
1000101101
11111010101
111110011011
1010001000100
11111011100100
111111001111011
1111111101110111
10101001000000000
111111111000000001
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #51:

score: 5
Accepted
time: 0ms
memory: 3640kb

input:

1
150 145

output:

Yes
0
00
001
0000
01010
001010
0011101
00111011
011011111
1000101101
11111010101
111110011011
1011001000100
11111011100100
111111001111011
1111111101110111
10101001000000000
111111111000000001
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #52:

score: 5
Accepted
time: 1ms
memory: 3988kb

input:

1
599 595

output:

Yes
0
00
001
0110
00110
001001
0011111
00010110
001011000
0000000000
00100110011
000100000010
0010010000101
00000000000000
110010101001000
1110010011010000
11110010001110010
111110000111100000
1100111000100100000
11111111101111000111
111111110100110000000
1111111111111100011110
111111101111010010110...

result:

ok good job! (1 test case)

Test #53:

score: 5
Accepted
time: 1ms
memory: 4356kb

input:

1
600 597

output:

Yes
0
00
001
0110
00110
001001
0011111
00010110
001011000
0000000000
00100110011
000100000010
0010010000101
00000000000000
110010101001000
1110010011010000
11110010001110010
111110000111100000
1100111000100100000
11111111101111000111
111111110100110000000
1111111111111100011110
111111101111010010110...

result:

ok good job! (1 test case)

Test #54:

score: 5
Accepted
time: 19ms
memory: 28408kb

input:

1
4999 4992

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000001
0000000000000010
00000000000000101
000000000000001111
0000000000000010100
00000000000000111111
000000000000001111010
0000000000000011111101
000000000000111111110...

result:

ok good job! (1 test case)

Test #55:

score: 5
Accepted
time: 15ms
memory: 28348kb

input:

1
4999 4994

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000001
0000000000000010
00000000000000101
000000000000001111
0000000000000010100
00000000000000111111
000000000000001111010
0000000000000011111101
000000000000111111110...

result:

ok good job! (1 test case)

Test #56:

score: 5
Accepted
time: 20ms
memory: 28496kb

input:

1
5000 4994

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000001
0000000000000010
00000000000000101
000000000000001111
0000000000000010100
00000000000000111111
000000000000001111010
0000000000000011111101
000000000000111111110...

result:

ok good job! (1 test case)

Test #57:

score: 5
Accepted
time: 22ms
memory: 28536kb

input:

1
5000 4994

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000001
0000000000000010
00000000000000101
000000000000001111
0000000000000010100
00000000000000111111
000000000000001111010
0000000000000011111101
000000000000111111110...

result:

ok good job! (1 test case)

Subtask #2:

score: 4
Accepted

Test #58:

score: 4
Accepted
time: 0ms
memory: 3716kb

input:

1
4 4

output:

No

result:

ok good job! (1 test case)

Test #59:

score: 4
Accepted
time: 0ms
memory: 3940kb

input:

1
5 10

output:

No

result:

ok good job! (1 test case)

Test #60:

score: 4
Accepted
time: 0ms
memory: 3676kb

input:

1
6 20

output:

No

result:

ok good job! (1 test case)

Test #61:

score: 4
Accepted
time: 0ms
memory: 3652kb

input:

1
7 35

output:

No

result:

ok good job! (1 test case)

Test #62:

score: 4
Accepted
time: 0ms
memory: 3712kb

input:

1
5 10

output:

No

result:

ok good job! (1 test case)

Test #63:

score: 4
Accepted
time: 0ms
memory: 3952kb

input:

1
6 19

output:

No

result:

ok good job! (1 test case)

Test #64:

score: 4
Accepted
time: 0ms
memory: 3616kb

input:

1
6 20

output:

No

result:

ok good job! (1 test case)

Test #65:

score: 4
Accepted
time: 0ms
memory: 3952kb

input:

1
7 33

output:

No

result:

ok good job! (1 test case)

Test #66:

score: 4
Accepted
time: 0ms
memory: 3604kb

input:

1
7 33

output:

No

result:

ok good job! (1 test case)

Test #67:

score: 4
Accepted
time: 1ms
memory: 3608kb

input:

1
4 3

output:

No

result:

ok good job! (1 test case)

Test #68:

score: 4
Accepted
time: 0ms
memory: 3716kb

input:

1
5 8

output:

No

result:

ok good job! (1 test case)

Test #69:

score: 4
Accepted
time: 0ms
memory: 3668kb

input:

1
6 17

output:

No

result:

ok good job! (1 test case)

Test #70:

score: 4
Accepted
time: 0ms
memory: 3712kb

input:

1
7 30

output:

No

result:

ok good job! (1 test case)

Test #71:

score: 4
Accepted
time: 0ms
memory: 3604kb

input:

2
3 0
3 1

output:

Yes
1
11
Yes
0
10

result:

ok good job! (2 test cases)

Test #72:

score: 4
Accepted
time: 0ms
memory: 3716kb

input:

2
3 0
3 1

output:

Yes
1
11
Yes
0
10

result:

ok good job! (2 test cases)

Test #73:

score: 4
Accepted
time: 0ms
memory: 3676kb

input:

1
4 2

output:

Yes
0
00
100

result:

ok good job! (1 test case)

Test #74:

score: 4
Accepted
time: 0ms
memory: 3644kb

input:

1
5 5

output:

Yes
0
00
100
1100

result:

ok good job! (1 test case)

Test #75:

score: 4
Accepted
time: 0ms
memory: 3684kb

input:

1
6 8

output:

Yes
0
00
000
1000
11000

result:

ok good job! (1 test case)

Test #76:

score: 4
Accepted
time: 0ms
memory: 3608kb

input:

1
7 14

output:

Yes
0
00
000
1000
11000
111000

result:

ok good job! (1 test case)

Test #77:

score: 4
Accepted
time: 0ms
memory: 3948kb

input:

1
6 5

output:

Yes
0
00
001
1000
11101

result:

ok good job! (1 test case)

Test #78:

score: 4
Accepted
time: 0ms
memory: 3712kb

input:

1
6 4

output:

Yes
0
00
011
1000
11101

result:

ok good job! (1 test case)

Test #79:

score: 4
Accepted
time: 0ms
memory: 3712kb

input:

1
7 7

output:

Yes
0
01
000
1101
11111
111001

result:

ok good job! (1 test case)

Test #80:

score: 4
Accepted
time: 0ms
memory: 3600kb

input:

1
7 6

output:

Yes
0
01
000
1101
11111
111011

result:

ok good job! (1 test case)

Test #81:

score: 4
Accepted
time: 0ms
memory: 3940kb

input:

1
7 8

output:

Yes
0
00
000
1101
11111
111001

result:

ok good job! (1 test case)

Test #82:

score: 4
Accepted
time: 0ms
memory: 3712kb

input:

1
6 7

output:

Yes
0
00
000
1000
11001

result:

ok good job! (1 test case)

Test #83:

score: 4
Accepted
time: 0ms
memory: 3940kb

input:

1
6 6

output:

Yes
0
00
000
1000
11101

result:

ok good job! (1 test case)

Test #84:

score: 4
Accepted
time: 0ms
memory: 3712kb

input:

1
7 11

output:

Yes
0
00
000
1001
11010
111001

result:

ok good job! (1 test case)

Test #85:

score: 4
Accepted
time: 0ms
memory: 3604kb

input:

1
7 11

output:

Yes
0
00
000
1001
11010
111001

result:

ok good job! (1 test case)

Test #86:

score: 4
Accepted
time: 0ms
memory: 3716kb

input:

1
7 13

output:

Yes
0
00
000
1000
11000
111001

result:

ok good job! (1 test case)

Test #87:

score: 4
Accepted
time: 0ms
memory: 3600kb

input:

1
6 6

output:

Yes
0
00
000
1000
11101

result:

ok good job! (1 test case)

Test #88:

score: 4
Accepted
time: 0ms
memory: 3672kb

input:

1
7 9

output:

Yes
0
00
000
1001
11111
111001

result:

ok good job! (1 test case)

Test #89:

score: 4
Accepted
time: 0ms
memory: 3616kb

input:

1
4 3

output:

No

result:

ok good job! (1 test case)

Test #90:

score: 4
Accepted
time: 0ms
memory: 3584kb

input:

1
5 10

output:

No

result:

ok good job! (1 test case)

Test #91:

score: 4
Accepted
time: 0ms
memory: 3712kb

input:

1
6 13

output:

No

result:

ok good job! (1 test case)

Test #92:

score: 4
Accepted
time: 0ms
memory: 3668kb

input:

1
7 23

output:

No

result:

ok good job! (1 test case)

Test #93:

score: 4
Accepted
time: 0ms
memory: 3676kb

input:

1
6 5

output:

Yes
0
00
001
1000
11101

result:

ok good job! (1 test case)

Test #94:

score: 4
Accepted
time: 0ms
memory: 3636kb

input:

1
6 2

output:

Yes
0
00
011
1010
11111

result:

ok good job! (1 test case)

Test #95:

score: 4
Accepted
time: 0ms
memory: 3948kb

input:

1
7 7

output:

Yes
0
01
000
1101
11111
111001

result:

ok good job! (1 test case)

Test #96:

score: 4
Accepted
time: 0ms
memory: 3936kb

input:

1
7 6

output:

Yes
0
01
000
1101
11111
111011

result:

ok good job! (1 test case)

Test #97:

score: 4
Accepted
time: 0ms
memory: 3712kb

input:

1
7 8

output:

Yes
0
00
000
1101
11111
111001

result:

ok good job! (1 test case)

Test #98:

score: 4
Accepted
time: 0ms
memory: 3608kb

input:

1
6 5

output:

Yes
0
00
001
1000
11101

result:

ok good job! (1 test case)

Test #99:

score: 4
Accepted
time: 0ms
memory: 3652kb

input:

1
6 4

output:

Yes
0
00
011
1000
11101

result:

ok good job! (1 test case)

Test #100:

score: 4
Accepted
time: 0ms
memory: 3676kb

input:

1
7 7

output:

Yes
0
01
000
1101
11111
111001

result:

ok good job! (1 test case)

Test #101:

score: 4
Accepted
time: 0ms
memory: 3904kb

input:

1
7 6

output:

Yes
0
01
000
1101
11111
111011

result:

ok good job! (1 test case)

Test #102:

score: 4
Accepted
time: 0ms
memory: 3904kb

input:

1
7 8

output:

Yes
0
00
000
1101
11111
111001

result:

ok good job! (1 test case)

Test #103:

score: 4
Accepted
time: 0ms
memory: 3716kb

input:

1
6 1

output:

Yes
0
00
011
1110
11111

result:

ok good job! (1 test case)

Test #104:

score: 4
Accepted
time: 0ms
memory: 3676kb

input:

1
6 1

output:

Yes
0
00
011
1110
11111

result:

ok good job! (1 test case)

Test #105:

score: 4
Accepted
time: 0ms
memory: 3672kb

input:

1
7 3

output:

Yes
0
01
010
1111
11111
111010

result:

ok good job! (1 test case)

Test #106:

score: 4
Accepted
time: 0ms
memory: 3948kb

input:

1
7 3

output:

Yes
0
01
010
1111
11111
111010

result:

ok good job! (1 test case)

Test #107:

score: 4
Accepted
time: 0ms
memory: 3948kb

input:

1
7 3

output:

Yes
0
01
010
1111
11111
111010

result:

ok good job! (1 test case)

Test #108:

score: 4
Accepted
time: 0ms
memory: 3940kb

input:

1
5 2

output:

Yes
0
01
110
1101

result:

ok good job! (1 test case)

Test #109:

score: 4
Accepted
time: 0ms
memory: 3608kb

input:

1
6 5

output:

Yes
0
00
001
1000
11101

result:

ok good job! (1 test case)

Test #110:

score: 4
Accepted
time: 0ms
memory: 3936kb

input:

2
4 1
3 0

output:

Yes
0
00
101
Yes
1
11

result:

ok good job! (2 test cases)

Test #111:

score: 4
Accepted
time: 0ms
memory: 3664kb

input:

1
6 1

output:

Yes
0
00
011
1110
11111

result:

ok good job! (1 test case)

Test #112:

score: 4
Accepted
time: 0ms
memory: 3936kb

input:

2
3 0
3 1

output:

Yes
1
11
Yes
0
10

result:

ok good job! (2 test cases)

Test #113:

score: 4
Accepted
time: 0ms
memory: 3676kb

input:

1
6 1

output:

Yes
0
00
011
1110
11111

result:

ok good job! (1 test case)

Test #114:

score: 4
Accepted
time: 0ms
memory: 3716kb

input:

1
6 4

output:

Yes
0
00
011
1000
11101

result:

ok good job! (1 test case)

Test #115:

score: 4
Accepted
time: 0ms
memory: 3720kb

input:

1
7 14

output:

Yes
0
00
000
1000
11000
111000

result:

ok good job! (1 test case)

Test #116:

score: 4
Accepted
time: 0ms
memory: 3684kb

input:

1
7 8

output:

Yes
0
00
000
1101
11111
111001

result:

ok good job! (1 test case)

Test #117:

score: 4
Accepted
time: 0ms
memory: 3936kb

input:

1
7 10

output:

Yes
0
00
000
1001
11110
111001

result:

ok good job! (1 test case)

Subtask #3:

score: 23
Accepted

Dependency #2:

100%
Accepted

Test #118:

score: 23
Accepted
time: 0ms
memory: 3940kb

input:

1
19 969

output:

No

result:

ok good job! (1 test case)

Test #119:

score: 23
Accepted
time: 0ms
memory: 3580kb

input:

1
20 1140

output:

No

result:

ok good job! (1 test case)

Test #120:

score: 23
Accepted
time: 0ms
memory: 3680kb

input:

1
19 968

output:

No

result:

ok good job! (1 test case)

Test #121:

score: 23
Accepted
time: 0ms
memory: 3948kb

input:

1
19 969

output:

No

result:

ok good job! (1 test case)

Test #122:

score: 23
Accepted
time: 0ms
memory: 3940kb

input:

1
20 1138

output:

No

result:

ok good job! (1 test case)

Test #123:

score: 23
Accepted
time: 0ms
memory: 3968kb

input:

1
20 1138

output:

No

result:

ok good job! (1 test case)

Test #124:

score: 23
Accepted
time: 0ms
memory: 3908kb

input:

1
20 1140

output:

No

result:

ok good job! (1 test case)

Test #125:

score: 23
Accepted
time: 0ms
memory: 3648kb

input:

1
19 846

output:

No

result:

ok good job! (1 test case)

Test #126:

score: 23
Accepted
time: 0ms
memory: 3608kb

input:

1
20 1003

output:

No

result:

ok good job! (1 test case)

Test #127:

score: 23
Accepted
time: 0ms
memory: 3720kb

input:

5
3 0
3 1
4 0
4 1
4 2

output:

Yes
1
11
Yes
0
10
Yes
0
00
111
Yes
0
00
101
Yes
0
00
100

result:

ok good job! (5 test cases)

Test #128:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

5
3 0
3 1
4 0
4 1
4 2

output:

Yes
1
11
Yes
0
10
Yes
0
00
111
Yes
0
00
101
Yes
0
00
100

result:

ok good job! (5 test cases)

Test #129:

score: 23
Accepted
time: 0ms
memory: 3940kb

input:

1
19 285

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
1000000000
11000000000
111000000000
1111000000000
11111000000000
111111000000000
1111111000000000
11111111000000000
111111111000000000

result:

ok good job! (1 test case)

Test #130:

score: 23
Accepted
time: 0ms
memory: 3648kb

input:

1
20 330

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
10000000000
110000000000
1110000000000
11110000000000
111110000000000
1111110000000000
11111110000000000
111111110000000000
1111111110000000000

result:

ok good job! (1 test case)

Test #131:

score: 23
Accepted
time: 0ms
memory: 3672kb

input:

1
19 274

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
1000000000
11000000000
111000000000
1111000000000
11111000000111
111111000000010
1111111000000111
11111111000000111
111111111000000001

result:

ok good job! (1 test case)

Test #132:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

1
19 271

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
1000000000
11000000000
111000000000
1111000000000
11111000000111
111111000011010
1111111000000111
11111111000000110
111111111000000001

result:

ok good job! (1 test case)

Test #133:

score: 23
Accepted
time: 0ms
memory: 3648kb

input:

1
20 289

output:

Yes
0
00
000
0000
00000
000000
0000001
00000011
000011111
0000000000
10000000000
110000000000
1110000000000
11111001100000
111111100000000
1111111111000001
11111111110000000
111101111000000000
1111111111000000001

result:

ok good job! (1 test case)

Test #134:

score: 23
Accepted
time: 0ms
memory: 3664kb

input:

1
20 328

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
10000000000
110000000000
1110000000000
11110000000000
111110000000000
1111110000000000
11111110000000000
111111110000000000
1111111111000000001

result:

ok good job! (1 test case)

Test #135:

score: 23
Accepted
time: 0ms
memory: 3668kb

input:

1
20 313

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000001
0000000000
10000000000
110000000000
1110000000000
11110000000000
111110100000000
1111111110000000
11111111110000000
111111111100000100
1111111111000000001

result:

ok good job! (1 test case)

Test #136:

score: 23
Accepted
time: 0ms
memory: 3656kb

input:

1
19 114

output:

Yes
0
01
011
0100
00000
000010
0100101
01001101
001010110
1100011010
11101001110
111010111110
1110111001111
11101111101110
111011111010111
1100000000000000
11111111100000001
111111111111111111

result:

ok good job! (1 test case)

Test #137:

score: 23
Accepted
time: 0ms
memory: 3684kb

input:

1
19 96

output:

Yes
0
01
011
0000
01010
010110
0101111
00111111
110111111
1101100000
11100111001
111110111000
1111110011111
11111111100100
111111111111011
1111111100000001
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #138:

score: 23
Accepted
time: 0ms
memory: 3684kb

input:

1
20 152

output:

Yes
0
00
011
0000
01010
001010
0011101
00111111
011011110
1000101101
11111010111
111110011011
1010000000100
11111011100100
111111001110011
1111111101110111
10101001000000000
111111111000000001
1111111111111111111

result:

ok good job! (1 test case)

Test #139:

score: 23
Accepted
time: 0ms
memory: 3716kb

input:

1
20 250

output:

Yes
0
00
000
0001
00000
000100
0001111
00000000
000001101
0000000000
10000000000
111010100000
1111010011000
11111100110010
111111100000110
1111111111000011
11111111110000110
111100000000000000
1111111111000000001

result:

ok good job! (1 test case)

Test #140:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

1
20 28

output:

Yes
0
00
000
0111
01100
011001
1110111
11111110
111011111
1111011010
11111111111
111111001011
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #141:

score: 23
Accepted
time: 0ms
memory: 3944kb

input:

1
19 231

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000111
1000000110
11000000101
111000000111
1111000011111
11111011100100
111111000011001
1111111101000011
11111111010000000
111111111000000001

result:

ok good job! (1 test case)

Test #142:

score: 23
Accepted
time: 0ms
memory: 3712kb

input:

1
19 270

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
1000000000
11000000000
111000000000
1111000000000
11111000000111
111111000011010
1111111000000111
11111111000000100
111111111000000001

result:

ok good job! (1 test case)

Test #143:

score: 23
Accepted
time: 0ms
memory: 3952kb

input:

1
20 258

output:

Yes
0
00
000
0001
00001
000100
0001111
00000000
000001101
0000000000
10000000000
110010000000
1111010011000
11111101110000
111111100000010
1111111111000011
11111111110000110
111100000000000000
1111111111000000001

result:

ok good job! (1 test case)

Test #144:

score: 23
Accepted
time: 0ms
memory: 3600kb

input:

1
20 263

output:

Yes
0
00
000
0001
00001
000000
0001011
00000000
000001101
0000000000
10000000000
110000000000
1111010011000
11111101110000
111111110000010
1111111111000011
11111111110000010
111100000000000000
1111111111000000001

result:

ok good job! (1 test case)

Test #145:

score: 23
Accepted
time: 0ms
memory: 3900kb

input:

1
20 286

output:

Yes
0
00
000
0000
00001
000000
0000001
00000011
000011111
0000000000
10000000000
110000000000
1110000000000
11111001100000
111111100000000
1111111111000001
11111111110000100
111100111000000000
1111111111000000001

result:

ok good job! (1 test case)

Test #146:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

1
19 241

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000011
1000000010
11000000111
111000000010
1111000011111
11111011100100
111111000011011
1111111100000010
11111111010010001
111111111000000001

result:

ok good job! (1 test case)

Test #147:

score: 23
Accepted
time: 0ms
memory: 3668kb

input:

1
20 286

output:

Yes
0
00
000
0000
00001
000000
0000001
00000011
000011111
0000000000
10000000000
110000000000
1110000000000
11111001100000
111111100000000
1111111111000001
11111111110000100
111100111000000000
1111111111000000001

result:

ok good job! (1 test case)

Test #148:

score: 23
Accepted
time: 0ms
memory: 3712kb

input:

1
19 294

output:

No

result:

ok good job! (1 test case)

Test #149:

score: 23
Accepted
time: 0ms
memory: 3600kb

input:

1
19 289

output:

No

result:

ok good job! (1 test case)

Test #150:

score: 23
Accepted
time: 0ms
memory: 3680kb

input:

1
20 338

output:

No

result:

ok good job! (1 test case)

Test #151:

score: 23
Accepted
time: 0ms
memory: 3708kb

input:

1
20 336

output:

No

result:

ok good job! (1 test case)

Test #152:

score: 23
Accepted
time: 0ms
memory: 3612kb

input:

1
20 335

output:

No

result:

ok good job! (1 test case)

Test #153:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

1
19 19

output:

Yes
0
00
001
0011
00100
010111
1010110
11111101
111111010
1111111100
11111100000
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #154:

score: 23
Accepted
time: 0ms
memory: 3712kb

input:

1
19 1

output:

Yes
0
00
011
0111
11110
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #155:

score: 23
Accepted
time: 0ms
memory: 3680kb

input:

1
20 2

output:

Yes
0
00
011
0110
11110
111111
1111110
11111111
111111111
1111111111
11111111111
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #156:

score: 23
Accepted
time: 0ms
memory: 3716kb

input:

1
20 40

output:

Yes
0
01
001
0010
00000
011001
0011011
11101111
111110110
1111111011
11111110110
100000000000
1111111000001
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #157:

score: 23
Accepted
time: 0ms
memory: 3724kb

input:

1
20 18

output:

Yes
0
00
001
0011
00100
010111
1010110
11111101
111111010
1111111101
11111100000
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #158:

score: 23
Accepted
time: 0ms
memory: 3652kb

input:

1
19 114

output:

Yes
0
01
011
0100
00000
000010
0100101
01001101
001010110
1100011010
11101001110
111010111110
1110111001111
11101111101110
111011111010111
1100000000000000
11111111100000001
111111111111111111

result:

ok good job! (1 test case)

Test #159:

score: 23
Accepted
time: 0ms
memory: 3940kb

input:

1
19 96

output:

Yes
0
01
011
0000
01010
010110
0101111
00111111
110111111
1101100000
11100111001
111110111000
1111110011111
11111111100100
111111111111011
1111111100000001
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #160:

score: 23
Accepted
time: 0ms
memory: 3716kb

input:

1
20 152

output:

Yes
0
00
011
0000
01010
001010
0011101
00111111
011011110
1000101101
11111010111
111110011011
1010000000100
11111011100100
111111001110011
1111111101110111
10101001000000000
111111111000000001
1111111111111111111

result:

ok good job! (1 test case)

Test #161:

score: 23
Accepted
time: 0ms
memory: 3936kb

input:

1
20 250

output:

Yes
0
00
000
0001
00000
000100
0001111
00000000
000001101
0000000000
10000000000
111010100000
1111010011000
11111100110010
111111100000110
1111111111000011
11111111110000110
111100000000000000
1111111111000000001

result:

ok good job! (1 test case)

Test #162:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

1
20 28

output:

Yes
0
00
000
0111
01100
011001
1110111
11111110
111011111
1111011010
11111111111
111111001011
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #163:

score: 23
Accepted
time: 0ms
memory: 3936kb

input:

1
19 68

output:

Yes
0
01
000
0101
01010
010100
0001101
00000010
110101110
1111011111
11010000100
111111110011
1111111101111
10000000000000
111111110000001
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #164:

score: 23
Accepted
time: 0ms
memory: 3940kb

input:

1
19 49

output:

Yes
0
01
000
0011
00000
011111
0010011
11101110
111100100
1111111011
11111110010
100000000000
1111111000001
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #165:

score: 23
Accepted
time: 0ms
memory: 3684kb

input:

1
20 21

output:

Yes
0
00
001
0011
00100
010111
1010010
11111101
111111010
1111111100
11111110000
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #166:

score: 23
Accepted
time: 0ms
memory: 3680kb

input:

1
20 34

output:

Yes
0
00
000
0110
01100
011010
1110111
11101110
111011111
1111011010
11111111111
111111000001
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #167:

score: 23
Accepted
time: 0ms
memory: 3724kb

input:

1
20 34

output:

Yes
0
00
000
0110
01100
011010
1110111
11101110
111011111
1111011010
11111111111
111111000001
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #168:

score: 23
Accepted
time: 0ms
memory: 3932kb

input:

2
13 8
7 3

output:

Yes
0
01
010
0111
01100
111111
1111101
11111111
111110000
1111111111
11111111111
111111111111
Yes
0
01
010
1111
11111
111010

result:

ok good job! (2 test cases)

Test #169:

score: 23
Accepted
time: 0ms
memory: 3652kb

input:

3
10 3
3 1
7 0

output:

Yes
0
01
000
0101
11111
110110
1101000
11111111
111111111
Yes
0
10
Yes
0
01
011
1111
11111
111100

result:

ok good job! (3 test cases)

Test #170:

score: 23
Accepted
time: 0ms
memory: 3940kb

input:

4
7 6
6 3
4 2
3 0

output:

Yes
0
01
000
1101
11111
111011
Yes
0
00
011
1010
11101
Yes
0
00
100
Yes
1
11

result:

ok good job! (4 test cases)

Test #171:

score: 23
Accepted
time: 0ms
memory: 3936kb

input:

2
17 120
3 0

output:

Yes
0
00
001
0000
01010
000110
0001101
00111011
110111110
1101100000
11100011111
111110100100
1111110011101
10111000000000
111111111111011
1111111100000001
Yes
1
11

result:

ok good job! (2 test cases)

Test #172:

score: 23
Accepted
time: 0ms
memory: 3652kb

input:

4
6 1
6 7
4 0
4 0

output:

Yes
0
00
011
1110
11111
Yes
0
00
000
1000
11001
Yes
0
00
111
Yes
0
00
111

result:

ok good job! (4 test cases)

Test #173:

score: 23
Accepted
time: 0ms
memory: 3672kb

input:

1
19 181

output:

Yes
0
00
000
0000
00000
000000
0011101
00111011
000010110
1000101101
11111010011
111110010011
1111000001101
11111011100100
111111000111111
1111111101100111
11010011000000000
111111111000000001

result:

ok good job! (1 test case)

Test #174:

score: 23
Accepted
time: 0ms
memory: 3952kb

input:

1
19 17

output:

Yes
0
00
001
0011
00000
010111
1010110
11111101
111111010
1111111101
11111100000
111111111111
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #175:

score: 23
Accepted
time: 0ms
memory: 3952kb

input:

1
20 170

output:

Yes
0
00
011
0011
00000
000101
0111010
00100100
000001000
0000000110
11010101101
111000110110
1111010011000
11111111110110
111111110101110
1111011111001000
11110111110110001
110001000100000000
1111111111000000001

result:

ok good job! (1 test case)

Test #176:

score: 23
Accepted
time: 0ms
memory: 3680kb

input:

1
20 30

output:

Yes
0
00
000
0110
01100
011000
1110111
11111110
111011111
1111011010
11111111111
111111001011
1111111111111
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #177:

score: 23
Accepted
time: 0ms
memory: 3940kb

input:

1
20 183

output:

Yes
0
00
011
0011
00000
000101
0101010
00100111
000001000
0000000100
11010101101
111000110100
1111010011000
11110111110110
111101110101110
1111011111010000
11110111110010011
111001000000000000
1111111111000000001

result:

ok good job! (1 test case)

Subtask #4:

score: 30
Accepted

Dependency #3:

100%
Accepted

Test #178:

score: 30
Accepted
time: 0ms
memory: 3680kb

input:

1
149 540274

output:

No

result:

ok good job! (1 test case)

Test #179:

score: 30
Accepted
time: 0ms
memory: 3608kb

input:

1
150 551300

output:

No

result:

ok good job! (1 test case)

Test #180:

score: 30
Accepted
time: 0ms
memory: 3612kb

input:

1
149 540272

output:

No

result:

ok good job! (1 test case)

Test #181:

score: 30
Accepted
time: 0ms
memory: 3588kb

input:

1
149 540272

output:

No

result:

ok good job! (1 test case)

Test #182:

score: 30
Accepted
time: 0ms
memory: 3648kb

input:

1
150 551299

output:

No

result:

ok good job! (1 test case)

Test #183:

score: 30
Accepted
time: 0ms
memory: 3620kb

input:

1
150 551299

output:

No

result:

ok good job! (1 test case)

Test #184:

score: 30
Accepted
time: 0ms
memory: 3580kb

input:

1
150 551299

output:

No

result:

ok good job! (1 test case)

Test #185:

score: 30
Accepted
time: 0ms
memory: 3604kb

input:

1
149 468391

output:

No

result:

ok good job! (1 test case)

Test #186:

score: 30
Accepted
time: 0ms
memory: 3948kb

input:

1
150 482173

output:

No

result:

ok good job! (1 test case)

Test #187:

score: 30
Accepted
time: 0ms
memory: 3700kb

input:

29
3 0
3 1
4 0
4 1
4 2
4 3
4 4
5 0
5 1
5 2
5 3
5 4
5 5
5 6
5 7
5 8
5 9
5 10
6 0
6 1
6 2
6 3
6 4
6 5
6 6
6 7
6 8
6 9
6 10

output:

Yes
1
11
Yes
0
10
Yes
0
00
111
Yes
0
00
101
Yes
0
00
100
No
No
Yes
0
01
111
1111
Yes
0
01
110
1111
Yes
0
01
110
1101
Yes
0
01
100
1101
Yes
0
00
100
1101
Yes
0
00
100
1100
No
No
No
No
No
Yes
0
00
011
1111
11111
Yes
0
00
011
1110
11111
Yes
0
00
011
1010
11111
Yes
0
00
011
1010
11101
Yes
0
00
011
1000
...

result:

ok good job! (29 test cases)

Test #188:

score: 30
Accepted
time: 0ms
memory: 3712kb

input:

26
3 0
3 1
4 0
4 1
4 2
5 0
5 1
5 2
5 3
5 4
5 5
6 0
6 1
6 2
6 3
6 4
6 5
6 6
6 7
6 8
7 0
7 1
7 2
7 3
7 4
7 5

output:

Yes
1
11
Yes
0
10
Yes
0
00
111
Yes
0
00
101
Yes
0
00
100
Yes
0
01
111
1111
Yes
0
01
110
1111
Yes
0
01
110
1101
Yes
0
01
100
1101
Yes
0
00
100
1101
Yes
0
00
100
1100
Yes
0
00
011
1111
11111
Yes
0
00
011
1110
11111
Yes
0
00
011
1010
11111
Yes
0
00
011
1010
11101
Yes
0
00
011
1000
11101
Yes
0
00
001
10...

result:

ok good job! (26 test cases)

Test #189:

score: 30
Accepted
time: 0ms
memory: 3968kb

input:

1
149 137825

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #190:

score: 30
Accepted
time: 0ms
memory: 3640kb

input:

1
150 140600

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #191:

score: 30
Accepted
time: 0ms
memory: 3936kb

input:

1
149 137691

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #192:

score: 30
Accepted
time: 0ms
memory: 3640kb

input:

1
149 137531

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #193:

score: 30
Accepted
time: 0ms
memory: 3616kb

input:

1
150 140481

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #194:

score: 30
Accepted
time: 0ms
memory: 3984kb

input:

1
150 140455

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #195:

score: 30
Accepted
time: 0ms
memory: 3748kb

input:

1
150 140554

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #196:

score: 30
Accepted
time: 1ms
memory: 3768kb

input:

1
149 77527

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #197:

score: 30
Accepted
time: 1ms
memory: 3772kb

input:

1
149 123264

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #198:

score: 30
Accepted
time: 0ms
memory: 3712kb

input:

1
150 123655

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #199:

score: 30
Accepted
time: 1ms
memory: 4000kb

input:

1
150 128371

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #200:

score: 30
Accepted
time: 0ms
memory: 3728kb

input:

1
150 124526

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #201:

score: 30
Accepted
time: 0ms
memory: 3688kb

input:

1
149 132911

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #202:

score: 30
Accepted
time: 1ms
memory: 3640kb

input:

1
149 129426

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #203:

score: 30
Accepted
time: 1ms
memory: 3772kb

input:

1
150 108351

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #204:

score: 30
Accepted
time: 1ms
memory: 3712kb

input:

1
150 132640

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #205:

score: 30
Accepted
time: 1ms
memory: 3732kb

input:

1
150 111366

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #206:

score: 30
Accepted
time: 0ms
memory: 3688kb

input:

1
149 135051

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #207:

score: 30
Accepted
time: 0ms
memory: 3936kb

input:

1
150 137826

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #208:

score: 30
Accepted
time: 0ms
memory: 3904kb

input:

1
149 137827

output:

No

result:

ok good job! (1 test case)

Test #209:

score: 30
Accepted
time: 0ms
memory: 3612kb

input:

1
149 137827

output:

No

result:

ok good job! (1 test case)

Test #210:

score: 30
Accepted
time: 0ms
memory: 3656kb

input:

1
150 140609

output:

No

result:

ok good job! (1 test case)

Test #211:

score: 30
Accepted
time: 0ms
memory: 3612kb

input:

1
150 140608

output:

No

result:

ok good job! (1 test case)

Test #212:

score: 30
Accepted
time: 0ms
memory: 3932kb

input:

1
150 140607

output:

No

result:

ok good job! (1 test case)

Test #213:

score: 30
Accepted
time: 0ms
memory: 3716kb

input:

1
149 379

output:

Yes
0
00
000
0101
00010
000100
0000000
00110111
011111111
0001001100
00101101000
000000100010
1001000100001
11010111000011
111000111111001
1111001111111011
11111100110111100
111111001010111001
1111111101110011111
11111111000011100100
111111111000111011101
1111111111001101111011
111111111111011000100...

result:

ok good job! (1 test case)

Test #214:

score: 30
Accepted
time: 0ms
memory: 3712kb

input:

1
149 298

output:

Yes
0
00
000
0000
00111
000010
0000000
00001001
011110010
0000000100
00000001000
100010111111
1110111011110
10000011101110
111101111110101
1111110110011111
11011000000000100
111111100011100100
1000101100110010001
11111111100101111111
110100111011000000000
1111111111100000000001
111111111111111111111...

result:

ok good job! (1 test case)

Test #215:

score: 30
Accepted
time: 0ms
memory: 3716kb

input:

1
150 75

output:

Yes
0
01
010
0101
01111
010100
0001101
00000000
110101110
1111011110
11011000100
111111110011
1111111101110
10000000000000
111111110000001
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #216:

score: 30
Accepted
time: 0ms
memory: 3644kb

input:

1
150 129

output:

Yes
0
01
011
0100
00100
001011
0110100
01001101
000010010
1100011010
11101001100
111010111110
1110111001111
11101111100011
111011111010111
1100000000000000
11111111100000001
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #217:

score: 30
Accepted
time: 0ms
memory: 3640kb

input:

1
150 44

output:

Yes
0
01
001
0011
00000
011101
0010011
11101111
111110100
1111111011
11111110110
100000000000
1111111000001
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #218:

score: 30
Accepted
time: 0ms
memory: 4000kb

input:

1
149 58042

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #219:

score: 30
Accepted
time: 0ms
memory: 3712kb

input:

1
149 22946

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000001
00000000000000000
000000000000000101
0000000000000001010
00000000000000000100
000000000000001101111
0000000000000011010110
000000000000010101101...

result:

ok good job! (1 test case)

Test #220:

score: 30
Accepted
time: 0ms
memory: 3712kb

input:

1
150 21975

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000001
000000000000000000
0000000000000000000
00000000000000000001
000000000000000011011
0000000000000000000110
000000000000000011111...

result:

ok good job! (1 test case)

Test #221:

score: 30
Accepted
time: 0ms
memory: 3616kb

input:

1
150 12279

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000011
000000000000110
0000000000011111
00000000000011110
000000000000110000
0000000000001001011
00000000000011110110
000000000000010111111
0000000000010111111110
000000000000101100101...

result:

ok good job! (1 test case)

Test #222:

score: 30
Accepted
time: 0ms
memory: 3944kb

input:

1
150 21044

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #223:

score: 30
Accepted
time: 0ms
memory: 3744kb

input:

1
149 3859

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000001
000000000000
0000000000001
00000000000011
000000000000111
0000000000001110
00000000000011000
000000000000111111
0000000000001111110
00000000000011100100
000000000000011111111
0000000000001110110010
000000000000111001000...

result:

ok good job! (1 test case)

Test #224:

score: 30
Accepted
time: 0ms
memory: 3700kb

input:

1
149 2822

output:

Yes
0
00
000
0000
00000
000000
0000000
00000001
000001011
0000001111
00000111110
000000011100
0000000111111
00000001000000
000001100100011
0000000011010111
00000101110100101
000000011000101000
0000001110010010010
00000111110100011111
000000111000000100100
0000000000000000000000
100000000000000000000...

result:

ok good job! (1 test case)

Test #225:

score: 30
Accepted
time: 0ms
memory: 3940kb

input:

1
150 11132

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000011
00000000000111
000000000001111
0000000000011100
00000000000000000
000000000001001011
0000000000011110110
00000000000010111111
000000000000111011110
0000000000010110111100
000000000001111111101...

result:

ok good job! (1 test case)

Test #226:

score: 30
Accepted
time: 0ms
memory: 3964kb

input:

1
150 2249

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000011
000000001100111
0000000000001110
00000000000000000
000000000000111001
0000000011001111111
00000000001100111111
100000000011110011101
1100000000000010011000
111000000000110111110...

result:

ok good job! (1 test case)

Test #227:

score: 30
Accepted
time: 0ms
memory: 3984kb

input:

1
150 29569

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #228:

score: 30
Accepted
time: 0ms
memory: 3732kb

input:

5
96 35791
6 0
32 367
13 49
3 1

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (5 test cases)

Test #229:

score: 30
Accepted
time: 0ms
memory: 3640kb

input:

5
37 1827
21 52
40 1995
44 1032
7 5

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000001
0000000000001111
00000000000011110
000000000000001100
1000000000000011000
11000000000000110111
111000000000001100110
1111000000000000101100
111110000000000001010...

result:

ok good job! (5 test cases)

Test #230:

score: 30
Accepted
time: 0ms
memory: 3664kb

input:

5
74 4427
43 920
25 422
5 5
3 0

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000001
0000000000000011
00000000000000111
000000000000001110
0000000000000011000
00000000000001111111
000000000000111111111
0000000000000111111100
000000000000000111111...

result:

ok good job! (5 test cases)

Test #231:

score: 30
Accepted
time: 0ms
memory: 3628kb

input:

2
125 56690
24 84

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (2 test cases)

Test #232:

score: 30
Accepted
time: 0ms
memory: 3920kb

input:

5
80 19621
46 3138
10 35
8 5
5 1

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000001
00000000000000000000
000000000000000000001
0000000000000000000000
000000000000000000000...

result:

ok good job! (5 test cases)

Test #233:

score: 30
Accepted
time: 0ms
memory: 3708kb

input:

1
149 205917

output:

No

result:

ok good job! (1 test case)

Test #234:

score: 30
Accepted
time: 1ms
memory: 3704kb

input:

1
149 91736

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #235:

score: 30
Accepted
time: 0ms
memory: 3680kb

input:

1
150 8430

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000001
00000000000
000000000000
0000000000001
00000000000111
000000000001111
0000000000011110
00000000010111111
000000000111011110
0000000000001111111
00000000010111110001
000000000001111111001
0000000000000000000100
000000000011101100010...

result:

ok good job! (1 test case)

Test #236:

score: 30
Accepted
time: 1ms
memory: 3724kb

input:

1
150 86431

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #237:

score: 30
Accepted
time: 0ms
memory: 3748kb

input:

1
150 139998

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Subtask #5:

score: 15
Accepted

Dependency #4:

100%
Accepted

Test #238:

score: 15
Accepted
time: 0ms
memory: 3948kb

input:

1
599 35641099

output:

No

result:

ok good job! (1 test case)

Test #239:

score: 15
Accepted
time: 0ms
memory: 3664kb

input:

1
600 35820200

output:

No

result:

ok good job! (1 test case)

Test #240:

score: 15
Accepted
time: 0ms
memory: 3584kb

input:

1
599 35641097

output:

No

result:

ok good job! (1 test case)

Test #241:

score: 15
Accepted
time: 0ms
memory: 3716kb

input:

1
599 35641098

output:

No

result:

ok good job! (1 test case)

Test #242:

score: 15
Accepted
time: 0ms
memory: 3720kb

input:

1
600 35820198

output:

No

result:

ok good job! (1 test case)

Test #243:

score: 15
Accepted
time: 0ms
memory: 3564kb

input:

1
600 35820199

output:

No

result:

ok good job! (1 test case)

Test #244:

score: 15
Accepted
time: 0ms
memory: 3616kb

input:

1
600 35820200

output:

No

result:

ok good job! (1 test case)

Test #245:

score: 15
Accepted
time: 0ms
memory: 3612kb

input:

1
599 31149736

output:

No

result:

ok good job! (1 test case)

Test #246:

score: 15
Accepted
time: 0ms
memory: 3604kb

input:

1
600 31381017

output:

No

result:

ok good job! (1 test case)

Test #247:

score: 15
Accepted
time: 0ms
memory: 3720kb

input:

92
3 0
3 1
4 0
4 1
4 2
4 3
4 4
5 0
5 1
5 2
5 3
5 4
5 5
5 6
5 7
5 8
5 9
5 10
6 0
6 1
6 2
6 3
6 4
6 5
6 6
6 7
6 8
6 9
6 10
6 11
6 12
6 13
6 14
6 15
6 16
6 17
6 18
6 19
6 20
7 0
7 1
7 2
7 3
7 4
7 5
7 6
7 7
7 8
7 9
7 10
7 11
7 12
7 13
7 14
7 15
7 16
7 17
7 18
7 19
7 20
7 21
7 22
7 23
7 24
7 25
7 26
7 27...

output:

Yes
1
11
Yes
0
10
Yes
0
00
111
Yes
0
00
101
Yes
0
00
100
No
No
Yes
0
01
111
1111
Yes
0
01
110
1111
Yes
0
01
110
1101
Yes
0
01
100
1101
Yes
0
00
100
1101
Yes
0
00
100
1100
No
No
No
No
No
Yes
0
00
011
1111
11111
Yes
0
00
011
1110
11111
Yes
0
00
011
1010
11111
Yes
0
00
011
1010
11101
Yes
0
00
011
1000
...

result:

ok good job! (92 test cases)

Test #248:

score: 15
Accepted
time: 0ms
memory: 3664kb

input:

81
3 0
3 1
4 0
4 1
4 2
5 0
5 1
5 2
5 3
5 4
5 5
6 0
6 1
6 2
6 3
6 4
6 5
6 6
6 7
6 8
7 0
7 1
7 2
7 3
7 4
7 5
7 6
7 7
7 8
7 9
7 10
7 11
7 12
7 13
7 14
8 0
8 1
8 2
8 3
8 4
8 5
8 6
8 7
8 8
8 9
8 10
8 11
8 12
8 13
8 14
8 15
8 16
8 17
8 18
8 19
8 20
9 0
9 1
9 2
9 3
9 4
9 5
9 6
9 7
9 8
9 9
9 10
9 11
9 12
9 ...

output:

Yes
1
11
Yes
0
10
Yes
0
00
111
Yes
0
00
101
Yes
0
00
100
Yes
0
01
111
1111
Yes
0
01
110
1111
Yes
0
01
110
1101
Yes
0
01
100
1101
Yes
0
00
100
1101
Yes
0
00
100
1100
Yes
0
00
011
1111
11111
Yes
0
00
011
1110
11111
Yes
0
00
011
1010
11111
Yes
0
00
011
1010
11101
Yes
0
00
011
1000
11101
Yes
0
00
001
10...

result:

ok good job! (81 test cases)

Test #249:

score: 15
Accepted
time: 1ms
memory: 4040kb

input:

1
599 8955050

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #250:

score: 15
Accepted
time: 1ms
memory: 4348kb

input:

1
600 8999900

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #251:

score: 15
Accepted
time: 1ms
memory: 4072kb

input:

1
599 8954812

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #252:

score: 15
Accepted
time: 1ms
memory: 3976kb

input:

1
599 8954621

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #253:

score: 15
Accepted
time: 1ms
memory: 4056kb

input:

1
600 8998543

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #254:

score: 15
Accepted
time: 1ms
memory: 4084kb

input:

1
600 8999826

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #255:

score: 15
Accepted
time: 1ms
memory: 4120kb

input:

1
600 8999510

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #256:

score: 15
Accepted
time: 3ms
memory: 4352kb

input:

1
599 8345787

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #257:

score: 15
Accepted
time: 3ms
memory: 4432kb

input:

1
599 8722378

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #258:

score: 15
Accepted
time: 3ms
memory: 4696kb

input:

1
600 8782693

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #259:

score: 15
Accepted
time: 2ms
memory: 4120kb

input:

1
600 8889455

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #260:

score: 15
Accepted
time: 3ms
memory: 4704kb

input:

1
600 8643126

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #261:

score: 15
Accepted
time: 3ms
memory: 4416kb

input:

1
599 7287746

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #262:

score: 15
Accepted
time: 0ms
memory: 4676kb

input:

1
599 8113340

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #263:

score: 15
Accepted
time: 3ms
memory: 4364kb

input:

1
600 6980363

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #264:

score: 15
Accepted
time: 0ms
memory: 4352kb

input:

1
600 6932760

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #265:

score: 15
Accepted
time: 1ms
memory: 4312kb

input:

1
600 8996064

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #266:

score: 15
Accepted
time: 0ms
memory: 4048kb

input:

1
599 8910201

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #267:

score: 15
Accepted
time: 1ms
memory: 4088kb

input:

1
600 8955051

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #268:

score: 15
Accepted
time: 0ms
memory: 3712kb

input:

1
599 8955056

output:

No

result:

ok good job! (1 test case)

Test #269:

score: 15
Accepted
time: 0ms
memory: 3716kb

input:

1
599 8955056

output:

No

result:

ok good job! (1 test case)

Test #270:

score: 15
Accepted
time: 0ms
memory: 3664kb

input:

1
600 8999908

output:

No

result:

ok good job! (1 test case)

Test #271:

score: 15
Accepted
time: 0ms
memory: 3668kb

input:

1
600 8999908

output:

No

result:

ok good job! (1 test case)

Test #272:

score: 15
Accepted
time: 0ms
memory: 3888kb

input:

1
600 8999904

output:

No

result:

ok good job! (1 test case)

Test #273:

score: 15
Accepted
time: 1ms
memory: 4088kb

input:

1
599 992

output:

Yes
0
00
000
0000
00001
000010
0000010
00000001
000011111
0001010110
00001011001
000000000000
0000110110011
00010111111111
000111111010110
0000000000000000
10000000000000000
110000000100000100
1111001011100100000
11111001011101000000
111111001110111100001
1111111000111111000010
111011111010100100000...

result:

ok good job! (1 test case)

Test #274:

score: 15
Accepted
time: 1ms
memory: 4356kb

input:

1
599 337

output:

Yes
0
00
011
0010
00101
010111
0000000
00010000
001111011
0110100110
00000001100
000100000000
1100100010101
11100110111001
100001011001000
1111101011110111
11111101001100000
111111111111000110
1111111111010011010
11111101111101010000
111111111111001110111
1101000000000000000000
111111111111000000000...

result:

ok good job! (1 test case)

Test #275:

score: 15
Accepted
time: 1ms
memory: 4068kb

input:

1
600 1774

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000001
0000000000
00000001011
000000010110
0000001101111
00000011011110
000000000000000
0000000101100001
00000011011111111
000011001000101111
0000000001101001100
10000011010011111001
110000010111010111010
1110001101101001100000
111110000101111011010...

result:

ok good job! (1 test case)

Test #276:

score: 15
Accepted
time: 1ms
memory: 4072kb

input:

1
600 275

output:

Yes
0
00
000
0011
00011
000000
0100101
01111011
000100100
0000001000
00000000000
110000010100
1110101001000
11110001001011
111110100110000
1111111111100110
11111011101001110
111110111110110000
1111101101100010001
11110010001000000000
111111111110000000001
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #277:

score: 15
Accepted
time: 1ms
memory: 4364kb

input:

1
600 102

output:

Yes
0
01
001
0000
01110
000110
0101111
00111111
110111111
1101100000
11100110001
111110111100
1111110011111
11111111000100
111111111111011
1111111100000001
11111111111111111
111111111111111111
1111111111111111111
11111111111111111111
111111111111111111111
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #278:

score: 15
Accepted
time: 1ms
memory: 4340kb

input:

1
599 355600

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #279:

score: 15
Accepted
time: 1ms
memory: 4076kb

input:

1
599 475943

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #280:

score: 15
Accepted
time: 1ms
memory: 4132kb

input:

1
600 120574

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #281:

score: 15
Accepted
time: 0ms
memory: 4100kb

input:

1
600 167075

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #282:

score: 15
Accepted
time: 0ms
memory: 4084kb

input:

1
600 302502

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #283:

score: 15
Accepted
time: 0ms
memory: 4136kb

input:

1
599 2048448

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #284:

score: 15
Accepted
time: 1ms
memory: 4364kb

input:

1
599 960012

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #285:

score: 15
Accepted
time: 1ms
memory: 4352kb

input:

1
600 141777

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #286:

score: 15
Accepted
time: 2ms
memory: 4092kb

input:

1
600 1243588

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #287:

score: 15
Accepted
time: 1ms
memory: 4320kb

input:

1
600 487443

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #288:

score: 15
Accepted
time: 1ms
memory: 3692kb

input:

6
74 16212
201 158009
162 66397
47 1639
112 49261
4 2

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000001
000000000000000000000...

result:

ok good job! (6 test cases)

Test #289:

score: 15
Accepted
time: 2ms
memory: 4252kb

input:

5
529 4771609
21 288
42 2532
5 0
3 1

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (5 test cases)

Test #290:

score: 15
Accepted
time: 2ms
memory: 4336kb

input:

9
481 2328203
26 209
27 95
12 7
13 41
23 129
9 25
6 2
3 0

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (9 test cases)

Test #291:

score: 15
Accepted
time: 0ms
memory: 4280kb

input:

5
552 4970748
9 15
16 122
14 105
8 12

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (5 test cases)

Test #292:

score: 15
Accepted
time: 1ms
memory: 3804kb

input:

7
222 86559
159 151626
166 15153
25 610
4 2
17 184
7 7

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (7 test cases)

Test #293:

score: 15
Accepted
time: 2ms
memory: 4228kb

input:

1
599 3698652

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #294:

score: 15
Accepted
time: 2ms
memory: 4436kb

input:

1
599 2692237

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #295:

score: 15
Accepted
time: 0ms
memory: 4068kb

input:

1
600 2516897

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #296:

score: 15
Accepted
time: 2ms
memory: 4196kb

input:

1
600 2315976

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #297:

score: 15
Accepted
time: 1ms
memory: 4068kb

input:

1
600 969595

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Subtask #6:

score: 23
Accepted

Dependency #1:

100%
Accepted

Dependency #2:

100%
Accepted

Dependency #3:

100%
Accepted

Dependency #4:

100%
Accepted

Dependency #5:

100%
Accepted

Test #298:

score: 23
Accepted
time: 1ms
memory: 3688kb

input:

379
3 0
3 1
4 0
4 1
4 2
5 0
5 1
5 2
5 3
5 4
6 0
6 1
6 2
6 3
6 4
6 5
6 6
7 0
7 1
7 2
7 3
7 4
7 5
7 6
7 7
7 8
7 9
8 0
8 1
8 2
8 3
8 4
8 5
8 6
8 7
8 8
8 9
8 10
8 11
8 12
9 0
9 1
9 2
9 3
9 4
9 5
9 6
9 7
9 8
9 9
9 10
9 11
9 12
9 13
9 14
9 15
9 16
10 0
10 1
10 2
10 3
10 4
10 5
10 6
10 7
10 8
10 9
10 10
10...

output:

Yes
1
11
Yes
0
10
Yes
0
00
111
Yes
0
00
101
Yes
0
00
100
Yes
0
01
111
1111
Yes
0
01
110
1111
Yes
0
01
110
1101
Yes
0
01
100
1101
Yes
0
00
100
1101
Yes
0
00
011
1111
11111
Yes
0
00
011
1110
11111
Yes
0
00
011
1010
11111
Yes
0
00
011
1010
11101
Yes
0
00
011
1000
11101
Yes
0
00
001
1000
11101
Yes
0
00
...

result:

ok good job! (379 test cases)

Test #299:

score: 23
Accepted
time: 12ms
memory: 19848kb

input:

10
4017 2564275
484 28572
129 402
192 3351
113 188
31 98
11 4
4 2
4 1
13 2

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (10 test cases)

Test #300:

score: 23
Accepted
time: 10ms
memory: 7836kb

input:

12
2006 756194
319 10305
479 35228
1295 125738
12 4
427 11376
111 1348
303 17209
39 52
3 0
3 1
3 0

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (12 test cases)

Test #301:

score: 23
Accepted
time: 9ms
memory: 12852kb

input:

9
3004 1215321
1223 238579
259 4165
424 33877
25 6
38 170
7 6
12 9
8 1

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (9 test cases)

Test #302:

score: 23
Accepted
time: 0ms
memory: 3668kb

input:

1
6 3

output:

Yes
0
00
011
1010
11101

result:

ok good job! (1 test case)

Test #303:

score: 23
Accepted
time: 0ms
memory: 3648kb

input:

1
7 4

output:

Yes
0
01
010
1111
11111
111011

result:

ok good job! (1 test case)

Test #304:

score: 23
Accepted
time: 0ms
memory: 3712kb

input:

1
19 37

output:

Yes
0
01
001
0110
00000
001001
0011011
11101111
111110110
1111111011
11111110110
100000000000
1111111100001
11111111111111
111111111111111
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #305:

score: 23
Accepted
time: 0ms
memory: 3680kb

input:

1
20 90

output:

Yes
0
01
011
0100
01010
010111
0111111
00111111
110111111
1101100000
11100111101
111110111000
1111110010111
11111111100110
111111111111011
1111111100000001
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #306:

score: 23
Accepted
time: 0ms
memory: 3976kb

input:

1
149 1610

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000011
00000000010
000000000100
0000000001100
00000000010001
000000000101111
0000000000011110
00000000010111100
000000000011011101
1000000011011111011
11000000000111111101
111000000111101101101
1111000011100001001011
111110010000011111011...

result:

ok good job! (1 test case)

Test #307:

score: 23
Accepted
time: 0ms
memory: 3688kb

input:

1
150 895

output:

Yes
0
00
000
0000
00001
000000
0000000
00000000
000000101
0000001111
00000111111
000000101100
0000001011001
00000100111011
000000101100110
1000111000001110
11000011001101110
111000110010110100
1111110011001110101
11110010110010000000
111111000001111110011
1111111000001111111011
111110000000100100010...

result:

ok good job! (1 test case)

Test #308:

score: 23
Accepted
time: 1ms
memory: 4348kb

input:

1
599 83482

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #309:

score: 23
Accepted
time: 1ms
memory: 4020kb

input:

1
600 23667

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000001
0000000000000000000
00000000000000000000
000000000000000000001
0000000000000000011011
000000000000000001001...

result:

ok good job! (1 test case)

Test #310:

score: 23
Accepted
time: 20ms
memory: 28688kb

input:

1
4999 3217919

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #311:

score: 23
Accepted
time: 29ms
memory: 28336kb

input:

1
4999 3832640

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #312:

score: 23
Accepted
time: 20ms
memory: 28752kb

input:

1
5000 980053

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #313:

score: 23
Accepted
time: 28ms
memory: 28760kb

input:

1
5000 1846859

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #314:

score: 23
Accepted
time: 20ms
memory: 28468kb

input:

1
5000 4406415

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #315:

score: 23
Accepted
time: 0ms
memory: 3904kb

input:

1
4 2

output:

Yes
0
00
100

result:

ok good job! (1 test case)

Test #316:

score: 23
Accepted
time: 0ms
memory: 3904kb

input:

1
5 4

output:

Yes
0
00
100
1101

result:

ok good job! (1 test case)

Test #317:

score: 23
Accepted
time: 0ms
memory: 3664kb

input:

1
6 6

output:

Yes
0
00
000
1000
11101

result:

ok good job! (1 test case)

Test #318:

score: 23
Accepted
time: 0ms
memory: 3652kb

input:

1
7 9

output:

Yes
0
00
000
1001
11111
111001

result:

ok good job! (1 test case)

Test #319:

score: 23
Accepted
time: 0ms
memory: 3652kb

input:

1
19 81

output:

Yes
0
01
010
0101
01111
010000
0001101
00001000
110101110
1111001110
11111000100
111111110011
1111111100110
11000000000000
111111110000001
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #320:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

1
20 90

output:

Yes
0
01
011
0100
01010
010111
0111111
00111111
110111111
1101100000
11100111101
111110111000
1111110010111
11111111100110
111111111111011
1111111100000001
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #321:

score: 23
Accepted
time: 0ms
memory: 3740kb

input:

1
149 5476

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000001
0000000010
00000000100
000000001111
0000000011110
00000000011100
000000001111011
0000000000000011
00000000111100001
000000000001110111
0000000010100100100
00000000111001011110
000000001010000110010
0000000101110110111111
000000001011000010000...

result:

ok good job! (1 test case)

Test #322:

score: 23
Accepted
time: 0ms
memory: 3704kb

input:

1
150 5550

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000001
000000000000011011
0000000000001110111
00000000000001111110
000000000000000010000
0000000000000000111111
000000000000111011101...

result:

ok good job! (1 test case)

Test #323:

score: 23
Accepted
time: 0ms
memory: 4120kb

input:

1
599 89401

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #324:

score: 23
Accepted
time: 1ms
memory: 4000kb

input:

1
600 89700

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #325:

score: 23
Accepted
time: 33ms
memory: 28412kb

input:

1
4999 6245001

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #326:

score: 23
Accepted
time: 24ms
memory: 28420kb

input:

1
5000 6247500

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #327:

score: 23
Accepted
time: 0ms
memory: 3884kb

input:

1
4 0

output:

Yes
0
00
111

result:

ok good job! (1 test case)

Test #328:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

1
5 2

output:

Yes
0
01
110
1101

result:

ok good job! (1 test case)

Test #329:

score: 23
Accepted
time: 0ms
memory: 3720kb

input:

1
6 3

output:

Yes
0
00
011
1010
11101

result:

ok good job! (1 test case)

Test #330:

score: 23
Accepted
time: 0ms
memory: 3628kb

input:

1
7 5

output:

Yes
0
01
010
1101
11111
111011

result:

ok good job! (1 test case)

Test #331:

score: 23
Accepted
time: 0ms
memory: 3912kb

input:

1
19 76

output:

Yes
0
01
010
0101
01111
010100
0001101
00001000
110101110
1111011110
11011000100
111111110011
1111111101110
10000000000000
111111110000001
1111111111111111
11111111111111111
111111111111111111

result:

ok good job! (1 test case)

Test #332:

score: 23
Accepted
time: 0ms
memory: 3940kb

input:

1
20 85

output:

Yes
0
01
011
0100
01000
011111
0111111
00111110
110111111
1101100000
11100111101
111110111001
1111110010111
11111111100111
111111111111011
1111111100000001
11111111111111111
111111111111111111
1111111111111111111

result:

ok good job! (1 test case)

Test #333:

score: 23
Accepted
time: 0ms
memory: 3752kb

input:

1
149 5475

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000001
0000000010
00000000100
000000001111
0000000011110
00000000011100
000000001111011
0000000000000011
00000000111100001
000000000001110111
0000000010100100100
00000000111001011110
000000001010000110010
0000000101110110111111
000000001011000010000...

result:

ok good job! (1 test case)

Test #334:

score: 23
Accepted
time: 0ms
memory: 3712kb

input:

1
150 5547

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000001
000000000000011011
0000000000001110111
00000000000001111110
000000000000000010000
0000000000000000111111
000000000000111011101...

result:

ok good job! (1 test case)

Test #335:

score: 23
Accepted
time: 1ms
memory: 4072kb

input:

1
599 89399

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #336:

score: 23
Accepted
time: 0ms
memory: 4132kb

input:

1
600 89699

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #337:

score: 23
Accepted
time: 23ms
memory: 28336kb

input:

1
4999 6244996

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #338:

score: 23
Accepted
time: 18ms
memory: 28444kb

input:

1
4999 6244998

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #339:

score: 23
Accepted
time: 24ms
memory: 28764kb

input:

1
5000 6247496

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #340:

score: 23
Accepted
time: 22ms
memory: 28492kb

input:

1
5000 6247496

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #341:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

1
4999 20808342499

output:

No

result:

ok good job! (1 test case)

Test #342:

score: 23
Accepted
time: 0ms
memory: 3944kb

input:

1
5000 20820835000

output:

No

result:

ok good job! (1 test case)

Test #343:

score: 23
Accepted
time: 0ms
memory: 3680kb

input:

1
4999 20808342499

output:

No

result:

ok good job! (1 test case)

Test #344:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

1
4999 20808342498

output:

No

result:

ok good job! (1 test case)

Test #345:

score: 23
Accepted
time: 0ms
memory: 3680kb

input:

1
4999 20808342499

output:

No

result:

ok good job! (1 test case)

Test #346:

score: 23
Accepted
time: 0ms
memory: 3588kb

input:

1
5000 20820834999

output:

No

result:

ok good job! (1 test case)

Test #347:

score: 23
Accepted
time: 0ms
memory: 3904kb

input:

1
5000 20820834999

output:

No

result:

ok good job! (1 test case)

Test #348:

score: 23
Accepted
time: 0ms
memory: 3720kb

input:

1
5000 20820835000

output:

No

result:

ok good job! (1 test case)

Test #349:

score: 23
Accepted
time: 0ms
memory: 3712kb

input:

1
5000 20820834999

output:

No

result:

ok good job! (1 test case)

Test #350:

score: 23
Accepted
time: 0ms
memory: 3648kb

input:

1
5000 20820834999

output:

No

result:

ok good job! (1 test case)

Test #351:

score: 23
Accepted
time: 0ms
memory: 3608kb

input:

1
4999 18290677170

output:

No

result:

ok good job! (1 test case)

Test #352:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

1
5000 18277696017

output:

No

result:

ok good job! (1 test case)

Test #353:

score: 23
Accepted
time: 0ms
memory: 3608kb

input:

527
3 0
3 1
4 0
4 1
4 2
4 3
4 4
5 0
5 1
5 2
5 3
5 4
5 5
5 6
5 7
5 8
5 9
5 10
6 0
6 1
6 2
6 3
6 4
6 5
6 6
6 7
6 8
6 9
6 10
6 11
6 12
6 13
6 14
6 15
6 16
6 17
6 18
6 19
6 20
7 0
7 1
7 2
7 3
7 4
7 5
7 6
7 7
7 8
7 9
7 10
7 11
7 12
7 13
7 14
7 15
7 16
7 17
7 18
7 19
7 20
7 21
7 22
7 23
7 24
7 25
7 26
7 2...

output:

Yes
1
11
Yes
0
10
Yes
0
00
111
Yes
0
00
101
Yes
0
00
100
No
No
Yes
0
01
111
1111
Yes
0
01
110
1111
Yes
0
01
110
1101
Yes
0
01
100
1101
Yes
0
00
100
1101
Yes
0
00
100
1100
No
No
No
No
No
Yes
0
00
011
1111
11111
Yes
0
00
011
1110
11111
Yes
0
00
011
1010
11111
Yes
0
00
011
1010
11101
Yes
0
00
011
1000
...

result:

ok good job! (527 test cases)

Test #354:

score: 23
Accepted
time: 1ms
memory: 3720kb

input:

437
3 0
3 1
4 0
4 1
4 2
5 0
5 1
5 2
5 3
5 4
5 5
6 0
6 1
6 2
6 3
6 4
6 5
6 6
6 7
6 8
7 0
7 1
7 2
7 3
7 4
7 5
7 6
7 7
7 8
7 9
7 10
7 11
7 12
7 13
7 14
8 0
8 1
8 2
8 3
8 4
8 5
8 6
8 7
8 8
8 9
8 10
8 11
8 12
8 13
8 14
8 15
8 16
8 17
8 18
8 19
8 20
9 0
9 1
9 2
9 3
9 4
9 5
9 6
9 7
9 8
9 9
9 10
9 11
9 12
9...

output:

Yes
1
11
Yes
0
10
Yes
0
00
111
Yes
0
00
101
Yes
0
00
100
Yes
0
01
111
1111
Yes
0
01
110
1111
Yes
0
01
110
1101
Yes
0
01
100
1101
Yes
0
00
100
1101
Yes
0
00
100
1100
Yes
0
00
011
1111
11111
Yes
0
00
011
1110
11111
Yes
0
00
011
1010
11111
Yes
0
00
011
1010
11101
Yes
0
00
011
1000
11101
Yes
0
00
001
10...

result:

ok good job! (437 test cases)

Test #355:

score: 23
Accepted
time: 23ms
memory: 28184kb

input:

1
4999 5205208750

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #356:

score: 23
Accepted
time: 26ms
memory: 28328kb

input:

1
5000 5208332500

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #357:

score: 23
Accepted
time: 21ms
memory: 28480kb

input:

1
4999 5205204564

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #358:

score: 23
Accepted
time: 17ms
memory: 28180kb

input:

1
4999 5205207651

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #359:

score: 23
Accepted
time: 25ms
memory: 28516kb

input:

1
4999 5205206252

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #360:

score: 23
Accepted
time: 23ms
memory: 28264kb

input:

1
5000 5208325001

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #361:

score: 23
Accepted
time: 29ms
memory: 28316kb

input:

1
5000 5208329137

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #362:

score: 23
Accepted
time: 21ms
memory: 28608kb

input:

1
5000 5208324886

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #363:

score: 23
Accepted
time: 23ms
memory: 28340kb

input:

1
5000 5208321567

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #364:

score: 23
Accepted
time: 22ms
memory: 28312kb

input:

1
5000 5208332281

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #365:

score: 23
Accepted
time: 138ms
memory: 50056kb

input:

1
4999 5135965230

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #366:

score: 23
Accepted
time: 32ms
memory: 28284kb

input:

1
4999 5204297521

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #367:

score: 23
Accepted
time: 149ms
memory: 50508kb

input:

1
4999 5183922040

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #368:

score: 23
Accepted
time: 151ms
memory: 50660kb

input:

1
5000 5155967728

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #369:

score: 23
Accepted
time: 156ms
memory: 50564kb

input:

1
5000 5187380758

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #370:

score: 23
Accepted
time: 136ms
memory: 50808kb

input:

1
5000 5194844191

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #371:

score: 23
Accepted
time: 150ms
memory: 50792kb

input:

1
5000 5181277861

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #372:

score: 23
Accepted
time: 171ms
memory: 50524kb

input:

1
5000 5162060211

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #373:

score: 23
Accepted
time: 138ms
memory: 47112kb

input:

1
4999 4069506833

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #374:

score: 23
Accepted
time: 114ms
memory: 48028kb

input:

1
4999 4300556425

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #375:

score: 23
Accepted
time: 131ms
memory: 47976kb

input:

1
4999 4348897699

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #376:

score: 23
Accepted
time: 139ms
memory: 50060kb

input:

1
5000 5030666205

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #377:

score: 23
Accepted
time: 145ms
memory: 49272kb

input:

1
5000 4693049796

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #378:

score: 23
Accepted
time: 136ms
memory: 48860kb

input:

1
5000 4571580553

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #379:

score: 23
Accepted
time: 140ms
memory: 50024kb

input:

1
5000 4914362477

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #380:

score: 23
Accepted
time: 147ms
memory: 48040kb

input:

1
5000 4287851573

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #381:

score: 23
Accepted
time: 67ms
memory: 28280kb

input:

1
4999 5202085001

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #382:

score: 23
Accepted
time: 59ms
memory: 28348kb

input:

1
5000 5205208751

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #383:

score: 23
Accepted
time: 0ms
memory: 3652kb

input:

1
4999 5205208752

output:

No

result:

ok good job! (1 test case)

Test #384:

score: 23
Accepted
time: 0ms
memory: 3716kb

input:

1
4999 5205208757

output:

No

result:

ok good job! (1 test case)

Test #385:

score: 23
Accepted
time: 0ms
memory: 3948kb

input:

1
4999 5205208758

output:

No

result:

ok good job! (1 test case)

Test #386:

score: 23
Accepted
time: 0ms
memory: 3616kb

input:

1
5000 5208332508

output:

No

result:

ok good job! (1 test case)

Test #387:

score: 23
Accepted
time: 0ms
memory: 3608kb

input:

1
5000 5208332507

output:

No

result:

ok good job! (1 test case)

Test #388:

score: 23
Accepted
time: 0ms
memory: 3936kb

input:

1
5000 5208332502

output:

No

result:

ok good job! (1 test case)

Test #389:

score: 23
Accepted
time: 0ms
memory: 3608kb

input:

1
5000 5208332509

output:

No

result:

ok good job! (1 test case)

Test #390:

score: 23
Accepted
time: 0ms
memory: 3676kb

input:

1
5000 5208332506

output:

No

result:

ok good job! (1 test case)

Test #391:

score: 23
Accepted
time: 23ms
memory: 28388kb

input:

1
4999 4509

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000001
0000000000000011
00000000000000111
000000000000001111
0000000000000011000
00000000000001111111
000000000000001111010
0000000000000011000100
000000000000000111111...

result:

ok good job! (1 test case)

Test #392:

score: 23
Accepted
time: 19ms
memory: 28404kb

input:

1
4999 1108

output:

Yes
0
00
001
0001
00000
001101
0011110
00110110
000001000
0000011011
00011110111
001001100101
0011111011001
00000100010010
000010001010111
0011010000101110
00000000000000000
100000000000000000
1100000011000101000
11110000111010011001
111110000110011100000
1111110010111011100010
111111100111011110001...

result:

ok good job! (1 test case)

Test #393:

score: 23
Accepted
time: 32ms
memory: 28416kb

input:

1
4999 2694

output:

Yes
0
00
000
0000
00000
000011
0000000
00000001
000011111
0000001111
00000101111
000011011001
0000001111111
00000101100100
000011000101010
0000000011110011
00001111110111100
000001011000100000
0000001111001011000
00001111110111111111
000011111101111101100
0000000000000000000000
100000000000000000000...

result:

ok good job! (1 test case)

Test #394:

score: 23
Accepted
time: 17ms
memory: 28428kb

input:

1
5000 3247

output:

Yes
0
00
000
0000
00000
000000
0000001
00000000
000000001
0000001011
00000001111
000000111111
0000011011101
00000000111110
000000111100100
0000000000100010
00000000011110011
000001111110111100
0000000011000100000
00000001110000011010
000001111110111111111
0000001111000000100100
000000000000000000000...

result:

ok good job! (1 test case)

Test #395:

score: 23
Accepted
time: 21ms
memory: 28428kb

input:

1
5000 251

output:

Yes
0
01
010
0011
00011
000000
0111001
01111111
010000100
0000001000
00000001000
110011010100
1110101101000
11110101001101
111110100110000
1111111111100110
11111111101001110
111110111110010000
1111111101100110001
11100010001000000000
111111111110000000001
1111111111111111111111
111111111111111111111...

result:

ok good job! (1 test case)

Test #396:

score: 23
Accepted
time: 23ms
memory: 28500kb

input:

1
5000 7242

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000001
0000000000000000000111
000000000000000011011...

result:

ok good job! (1 test case)

Test #397:

score: 23
Accepted
time: 27ms
memory: 28760kb

input:

1
5000 13031

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #398:

score: 23
Accepted
time: 31ms
memory: 28532kb

input:

1
5000 5260

output:

Yes
0
00
000
0000
00000
000000
0000000
00000001
000000011
0000000000
00000001111
000000001111
0000000011100
00000001011001
000000001111011
0000000111100101
00000001111111111
000000000001110110
0000001110110110110
00000000111011011101
000000011111111111001
0000000100110000000000
000000111111111010100...

result:

ok good job! (1 test case)

Test #399:

score: 23
Accepted
time: 25ms
memory: 28392kb

input:

1
4999 72889929

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #400:

score: 23
Accepted
time: 19ms
memory: 28336kb

input:

1
4999 21771753

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #401:

score: 23
Accepted
time: 23ms
memory: 28376kb

input:

1
4999 24307832

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #402:

score: 23
Accepted
time: 24ms
memory: 28384kb

input:

1
5000 11643247

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #403:

score: 23
Accepted
time: 24ms
memory: 28496kb

input:

1
5000 9670251

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #404:

score: 23
Accepted
time: 24ms
memory: 28476kb

input:

1
5000 34307242

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #405:

score: 23
Accepted
time: 24ms
memory: 28708kb

input:

1
5000 43678031

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #406:

score: 23
Accepted
time: 23ms
memory: 28488kb

input:

1
5000 33625260

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #407:

score: 23
Accepted
time: 26ms
memory: 28612kb

input:

1
4999 153346012

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #408:

score: 23
Accepted
time: 71ms
memory: 31836kb

input:

1
4999 1206175180

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #409:

score: 23
Accepted
time: 60ms
memory: 28784kb

input:

1
4999 709629300

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #410:

score: 23
Accepted
time: 69ms
memory: 30716kb

input:

1
5000 1005829742

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #411:

score: 23
Accepted
time: 63ms
memory: 32240kb

input:

1
5000 1224201505

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #412:

score: 23
Accepted
time: 58ms
memory: 30176kb

input:

1
5000 925455260

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #413:

score: 23
Accepted
time: 58ms
memory: 28764kb

input:

1
5000 709941552

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #414:

score: 23
Accepted
time: 38ms
memory: 28424kb

input:

1
5000 313686067

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #415:

score: 23
Accepted
time: 49ms
memory: 16492kb

input:

9
2619 672433584
922 3971218
635 273073
59 6252
366 236521
275 738448
68 4274
52 2575
3 0

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (9 test cases)

Test #416:

score: 23
Accepted
time: 39ms
memory: 11748kb

input:

10
2065 326616173
635 5454133
258 223488
1465 94003613
501 3203523
15 124
12 19
32 380
12 11
5 0

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (10 test cases)

Test #417:

score: 23
Accepted
time: 39ms
memory: 17036kb

input:

10
133 69738
690 5626670
3110 547518324
177 104754
793 12918527
24 427
54 785
5 2
9 11
4 2

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (10 test cases)

Test #418:

score: 23
Accepted
time: 24ms
memory: 7852kb

input:

7
2022 39262075
1722 36740513
1085 20749788
88 20124
59 7319
18 7
4 1

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (7 test cases)

Test #419:

score: 23
Accepted
time: 38ms
memory: 17640kb

input:

9
3338 546623099
251 516661
639 2660568
481 1785023
91 21946
17 169
108 35582
65 11044
9 21

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (9 test cases)

Test #420:

score: 23
Accepted
time: 120ms
memory: 47428kb

input:

1
4999 4177820680

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #421:

score: 23
Accepted
time: 161ms
memory: 48428kb

input:

1
4999 4513673892

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #422:

score: 23
Accepted
time: 0ms
memory: 3600kb

input:

1
4999 13400105025

output:

No

result:

ok good job! (1 test case)

Test #423:

score: 23
Accepted
time: 79ms
memory: 33780kb

input:

1
5000 1525081015

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #424:

score: 23
Accepted
time: 83ms
memory: 36672kb

input:

1
5000 2039452757

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #425:

score: 23
Accepted
time: 76ms
memory: 32244kb

input:

1
5000 1256450563

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #426:

score: 23
Accepted
time: 87ms
memory: 35512kb

input:

1
5000 1817271204

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Test #427:

score: 23
Accepted
time: 47ms
memory: 28460kb

input:

1
5000 487140772

output:

Yes
0
00
000
0000
00000
000000
0000000
00000000
000000000
0000000000
00000000000
000000000000
0000000000000
00000000000000
000000000000000
0000000000000000
00000000000000000
000000000000000000
0000000000000000000
00000000000000000000
000000000000000000000
0000000000000000000000
000000000000000000000...

result:

ok good job! (1 test case)

Extra Test:

score: 0
Extra Test Passed