SUBSEQ implementation for lists