Module Expr Str Assign NameStore Str ClassDef bases body FunctionDef arguments args NameParam NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr Assign NameStore ListLoad Expr Call AttributeLoad NameLoad attr NameLoad ListLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Expr Call AttributeLoad NameLoad attr NameLoad For TupleStore NameStore NameStore Call NameLoad NameLoad body If BoolOpAnd CompareGtE BinOpSub NameLoad Num Num CompareEq NameLoad SubscriptLoad NameLoad Index BinOpSub NameLoad Num body Continue Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Slice BinOpAdd NameLoad Num BinOpAdd NameLoad ListLoad NameLoad NameLoad decorator_list decorator_list If CompareEq NameLoad Str body Print Call AttributeLoad Call NameLoad attr ListLoad Num Num Num
N/A N/A 
Given a collection of integers that might contain duplicates, S, return all possible subsets.

Note:
Elements in a subset must be in non-descending order.
The solution set must not contain duplicate subsets.
For example,
If S = [1,2,2], a solution is:

[
  [2],
  [1],
  [1,2,2],
  [2,2],
  [1,2],
  []
]
 N/A __author__ Danyang Solution N/A N/A subsetsWithDup N/A N/A self S N/A N/A N/A 
        dfs
        notice the skipping
        :param S: a list of integer
        :return: a list of lists of integer
         N/A N/A N/A S sort N/A result N/A N/A N/A N/A self get_subset S N/A result N/A result N/A get_subset N/A N/A self S current result N/A N/A N/A N/A N/A result append current N/A N/A ind val N/A enumerate S N/A N/A N/A N/A N/A ind 1 0 N/A val N/A S N/A N/A ind 1 N/A N/A N/A N/A N/A self get_subset N/A S N/A N/A ind 1 N/A current N/A val result N/A N/A N/A N/A __name__ __main__ N/A N/A N/A N/A N/A Solution subsetsWithDup N/A 1 2 3