Subsequence and subset of the array

39 Views Asked by At

I have a doubt between the subsequence and subset of the array. Suppose I have an array:

nums = [1,2,3]

output = [[],[1],[2],[1,2],[3],[1,3],[2,3],[1,2,3]]

Whether output contains subsequence or subset of the nums ?

Subsequence means maintaing the relative order but may/may not be contigous. And subset means any combination of elements.

So I think we can say output conatins both subsequence and subset of nums ?

Can anyone help me in clarifying it?

0

There are 0 best solutions below