I have the next predicate which will generate all subsets from a lists:
candidate([],[]). candidate([H|T],[H|R]):- candidate(T,R). candidate([_|T],R):-