Drivers are concerned with the mileage their automobiles get. One driver has kept track of several tankfuls

Question:

Drivers are concerned with the mileage their automobiles get. One driver has kept track of several tankfuls of gasoline by recording the miles driven and gallons used for each tankful. Develop a C# app that will input the miles driven and gallons used (both as integers) for each tankful. The app should calculate and display the miles per gallon obtained for each tankful and display the combined miles per gallon obtained for all tankfuls up to this point. All averaging calculations should produce floating-point results. Display the results rounded to the nearest hundredth. Use the Console class’s Read Line method and sentinel-controlled iteration to obtain the data from the user.

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question

Visual C# How to Program

ISBN: 978-0134601540

6th edition

Authors: Paul J. Deitel, Harvey Deitel

Question Posted: