Pseudo code at the moment