A. 递归实现指数型枚举

    Type: Default 1000ms 256MiB

递归实现指数型枚举

You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.

Description

从 1-n 这 n个整数中随机选取任意多个,输出所有可能的选择方案。

Input

输入一个整数n(1<=n<=15)。

Output

每行输出一种方案。同一行内的数必须升序排列,相邻两个数用恰好1个空格隔开。 对于没有选任何数的方案,输出空行。

Samples

3

3
2
2 3
1
1 3
1 2
1 2 3

Limitation

1s, 1024KiB for each test case.

3.22

Not Attended
Status
Done
Rule
ACM/ICPC
Problem
7
Start at
2025-3-22 14:00
End at
2025-4-12 10:00
Duration
500 hour(s)
Host
Partic.
4