rename 'stack' to 'list' since it does more job now