began with stack implementation