How to design flawless sequences of tasks