GlobalData interview question

Snakes and ladders