refactoring of sequence and bind