Datahut Interview Question

my straightness, knowledge in python