EclecticIQ interview question

Code review for python code