Introduced two new functions.

These functions are called goingUp and goingDown, they are helper
functions that will be used in simulator.