Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

code in c++ Exercise#2: Number of Bottles The capacity of a plastic bottle is 2.3 liters. The cost of filling one bottle with petrol is

image text in transcribed code in c++
Exercise#2: Number of Bottles The capacity of a plastic bottle is 2.3 liters. The cost of filling one bottle with petrol is 1.Z and the selling price of one bottle is 2.5. Write a C++ program that prompts the user to enter the amount of petrol to be used, then calculates the number of bottles needed for that amount, the cost of filling all bottles, the selling price of all bottles, and the profit of selling all bottles. (0.5) Sample input/output: ( 21.7 Enter the petrol amount: 50 For 50 liters of petrol: The number of bottles is 22- The filling cost is 37.4 The selling price is 55 The profit is 17.6 21.3 22 21.7 22 21.3 21 21.3 to 5 = 21

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Machine Learning And Knowledge Discovery In Databases European Conference Ecml Pkdd 2014 Nancy France September 15 19 2014 Proceedings Part 3 Lnai 8726

Authors: Toon Calders ,Floriana Esposito ,Eyke Hullermeier ,Rosa Meo

2014th Edition

3662448440, 978-3662448441

More Books

Students also viewed these Databases questions