Lightspeed interview question

Theoretical python Code review of given scripts