枚举子集
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.
题目描述
今有 n 位同学,可以从中选出任意名同学参加合唱。
请输出所有可能的选择方案。
输入格式
- 仅一行,一个正整数 n。
输出格式
- 若干行,每行表示一个选择方案。
- 每一种选择方案用一个字符串表示,其中第 i 位为 Y 则表示第 i 名同学参加合唱;为 N 则表示不参加。
- 需要以字典序输出答案。
样例
3
NNN
NNY
NYN
NYY
YNN
YNY
YYN
YYY
提示
对于 100% 的数据,保证 1≤n≤10。
黑猫白银级公开赛05
- Status
- Done
- Rule
- OI
- Problem
- 4
- Start at
- 2024-5-5 11:15
- End at
- 2024-5-13 19:15
- Duration
- 200 hour(s)
- Host
- Partic.
- 8