LeetCode 0077 - Combinations
Contents
Combinations
Desicription
Given two integers n and k, return all possible combinations of k numbers out of 1 … n.
For example,
If n = 4 and k = 2, a solution is:
1 | [ |
Solution
1 | class Solution { |
Given two integers n and k, return all possible combinations of k numbers out of 1 … n.
For example,
If n = 4 and k = 2, a solution is:
1 | [ |
1 | class Solution { |