Weekend interview question

Make an elevator simulation in typescript