Thursday, July 4, 2024

Puzzle | Selling Chocolates

Ram and Shyam were selling chocolates. Ram was selling at the rate of 2 pieces/rupee and Shyam was selling at the rate of 3 pieces/rupee. Now both of them decided that they will mix their chocolates and sell them at the rate of 5 pieces for 2 rupees.
Now after selling whole chocolates, they found that the total collection is rupees 7 less than what they would get by selling them separately.

Note : Initially both have equal number of chocolates.

Q. Find how many chocolates each of them had initially?

Answer: 210

Explanation:

Let x be the number of chocolates each of them had initially. Total money earned when they sell chocolates separately: x/2 + x/3.
Total money earned if they sell in a combined manner: (2*x)/(5/2)
According to the problem: x/2 + x/3 =(2*x)/(5/2) + 7
Solving the above equation, we get the value of x = 210.

Feeling lost in the world of random DSA topics, wasting time without progress? It’s time for a change! Join our DSA course, where we’ll guide you on an exciting journey to master DSA efficiently and on schedule.
Ready to dive in? Explore our Free Demo Content and join our DSA course, trusted by over 100,000 neveropen!

Nokonwaba Nkukhwana
Experience as a skilled Java developer and proven expertise in using tools and technical developments to drive improvements throughout a entire software development life cycle. I have extensive industry and full life cycle experience in a java based environment, along with exceptional analytical, design and problem solving capabilities combined with excellent communication skills and ability to work alongside teams to define and refine new functionality. Currently working in springboot projects(microservices). Considering the fact that change is good, I am always keen to new challenges and growth to sharpen my skills.
RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments