Pseudo code for work code