This repository aims to solve and create new problems from different spheres of coding. A path to help students to get access to solutions and discuss their doubts.
Chef has allocated himself a budget of P rupees to buy Diwali crackers. There are only 3 types of crackers available in the market and each type of cracker can be bought any number of times.
Fuljhari, where each costs a rupees
Anar, where each costs b rupees
Chakri, where each costs c rupees
The crackers have the following interesting properties:-
A Fuljhari can be lit on its own
To light an Anar, you will need x Fuljharis
To light a Chakri, you will need y Fuljharis
What's the maximum total of Anars and Chakris that Chef can light up with his given budget.
Enter link to the question(if question belongs to any online platform) -
Enter your question -
Chef has allocated himself a budget of P rupees to buy Diwali crackers. There are only 3 types of crackers available in the market and each type of cracker can be bought any number of times.
The crackers have the following interesting properties:-
What's the maximum total of Anars and Chakris that Chef can light up with his given budget.
Enter link to the question(if question belongs to any online platform) -
https://www.codechef.com/START13C/problems/DIWALI1
Tags for the question(eg - Array, Basic, Stack, etc.) -
Greedy, math, implementation