Help me in solving LB01E problem

My issue

Learning course: Python for problem solving - 1
Problem Link: CodeChef: Practical coding for everyone


Hope this helps