No Adjacent Ones

EasyProblem #49
Time LimitMemoryInputOutput
1 s64 MBstdinstdout

Don't worry about Time Complexity for this problem

A hotel corridor has rooms in a row. Every room is either empty or occupied, and the manager has one rule: two occupied rooms may never be next to each other.

Write down for an empty room and for an occupied one, and every allowed arrangement of the corridor becomes an array of digits in which no two s stand side by side.

Print all of them.

The arrangements must come out in increasing order, reading each array as a number - so the all-empty corridor is first, and the arrangement starting with the most occupied rooms at the front is last.

Input

The only line of input contains a single integer - the number of rooms.

Output

Print every allowed arrangement on its own line, as digits separated by single spaces, in the order described above.

Example

Input
4
Output
0 0 0 0
0 0 0 1
0 0 1 0
0 1 0 0
0 1 0 1
1 0 0 0
1 0 0 1
1 0 1 0

There are eight arrangements for . Arrays like 0 1 1 0 and 1 1 0 0 are missing because they put two occupied rooms next to each other.

Constraints

Submit your solution