Given the number N
print all strings of length N
consisting of zeros and ones in lexicographic order.
Input
Given a single number N
(natural, \(1 <= N <= 10\))
Imprint
It is necessary to output all strings of length N
consisting of zeros and ones in lexicographic order, one per line.
Examples
# |
Input |
Output |
1 |
2 |
00
01
10
11 |