Module: Permutations


Problem

2 /5


Binary strings of given length in reverse order

Problem

Given the number N print all strings of length N consisting of zeros and ones in reverse lexicographic order.

Input
Single number specified N (\(1 <= N <= 10\)).
 
Output
It is necessary to output all strings of length N consisting of zeros and ones in reverse lexicographic order.

 
Examples
# Input Output
1 2 11
10
01
00