the recursive way is really simple:

```
def combine(self, n, k):
if k==1:
return [[i+1] for i in range(n)]
return [r+[n] for r in self.combine(n-1, k-1)]+self.combine(n-1,k) if n-1>=k else [r+[n] for r in self.combine(n-1, k-1)]
```

You can certainly combine this thing into one line, but there is no point doing so.

The DP way:

```
def combine(self, n, k):
base=[[[j] for j in xrange(1, i+1)] for i in xrange(1, n+1)]
for height in xrange(k-1):
newBase=[[]]
for i in xrange(1, len(base)):
newBase.append(newBase[-1]+[b+[height+i+1] for b in base[i-1]])
base=newBase[1:]
return base[-1]
```

The var height means k values 1 to k, I did not find a better name.

DP runs ~60ms, recursive ~68ms, decent for python.