I am facing runtime error and I can't seem to find the issue. The code is here. Any help is appreciated.
Problem Statement :
# | User | Rating |
---|---|---|
1 | tourist | 3803 |
2 | jiangly | 3707 |
3 | Benq | 3627 |
4 | ecnerwala | 3584 |
5 | orzdevinwang | 3573 |
6 | Geothermal | 3569 |
6 | cnnfls_csy | 3569 |
8 | Radewoosh | 3542 |
9 | jqdai0815 | 3532 |
10 | gyh20 | 3447 |
# | User | Contrib. |
---|---|---|
1 | awoo | 163 |
2 | maomao90 | 160 |
3 | adamant | 159 |
4 | maroonrk | 152 |
5 | -is-this-fft- | 150 |
6 | atcoder_official | 148 |
6 | SecondThread | 148 |
8 | nor | 147 |
9 | TheScrasse | 146 |
10 | Petr | 144 |
I am facing runtime error and I can't seem to find the issue. The code is here. Any help is appreciated.
In this problem you have to find the permutations using the first N English capital letters. Since there can be many permutations, you have to print the first K permutations.
Input Input starts with an integer T (≤ 100), denoting the number of test cases.
Each case contains two integers N, K (1 ≤ N ≤ 26, 1 ≤ K ≤ 30).
Output For each case, print the case number in a line. Then print the first K permutations that contain the first N English capital letters in alphabetical order. If there are less than K permutations then print all of them.
Name |
---|