Zeros and ones

Write a program that prints all the combinations of zz zeros and oo ones such that z+u=nz + u = n, for a given nn.

Input

The input consists of a natural 0<n<110 < n < 11.

Output

Your program must print all the combinations in lexicographical order (look the instance), one per line, the characters separated by spaces.

Author: Salvador Roura

Problem information

Author: Unknown
Translator: Carlos Molina

Generation: 2026-01-25T10:10:01.374Z

© Jutge.org, 2006–2026.
https://jutge.org