Bot saves princess - 2

Problem Name:
Bot saves princess - 2
Site:HackerRank
Links:
Tags:
Problem setters: