Given $N, K, L$, construct two binary strings $S$ and $T$ such that:
- Both $S$ and $T$ have length $N$.
- $S$ contains exactly $K$ ones.
- $T$ contains exactly $L$ ones.
Subject to these conditions, you want to minimize:
- The maximum number of ones in the binary string $R_i$ where $R_i = S_i \operatorname{and} T_i$, after applying any cyclic shift to $S$ and $T$.
Input
The input consists of a single line containing three integers $N, K, L$. It is guaranteed that $0 \leq K, L \leq N$.
Output
The first line of the output contains an integer representing the minimum value for the optimal construction.
The next line describes the constructed string $S$.
The next line describes the constructed string $T$.
If there are multiple valid solutions, you may output any one of them.
Examples
Input 1
6 4 3
Output 1
2
011011
101010
Input 2
5 2 0
Output 2
0
01001
00000
Input 3
10 7 6
Output 3
5
1101100111
1110001101
Subtasks
| Subtask | Score | Additional Constraints |
|---|---|---|
| $1$ | $5$ | $1 \leq N \leq 13$ |
| $2$ | $50$ | $1 \leq N \leq 5\,000$ |
| $3$ | $45$ | $1 \leq N \leq 500\,000$ |
Specifically, if your program outputs the correct result on the first line but the constructed solution is incorrect, you can receive $20\%$ of the points for that test case.