Answered step by step
Verified Expert Solution
Question
1 Approved Answer
You are living in Bangalore and want to travel from Bangalore to Ahmedabad and initially, you have M rupees. You are given the cost of
You are living in Bangalore and want to travel from Bangalore to
Ahmedabad and initially, you have rupees. You are given the cost of a
Gold coin, a Silver coin and a Bronze coin in Bangalore and Ahmedabad
in arrays and A respectively. You can buy at most one type of coin in
Bangalore according to your money and selt them in Ahmedabad. You
have to return the maximum money you can have in Ahmedabad.
Example :
Input:
Output:
Explanation:
You can buy gold coins in Bangalore in rupees and sell
them in Ahmedabad
and finally you have rupees in Ahmedabad.
Example :
IUser function Template for python
class solution:
def MaxMoney self M B A:
# code here
Land Driven rode frids
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started