//Castulo Jason Quintero CSC5 Chapter 3, P. 143, #1
//
/**************************************************************
*
* Compute Miles per Gallon
* ____________________________________________________________
* This program calculate the miles per gallon.
*
* Computation is based on the formula:
* MPG = mileRange / tankCapacity
* ____________________________________________________________
* INPUT
* tankCapacity: Gas tank capacity in gallons
* mileRange: Range of Miles that can be driven
*
* OUTPUT
* MPG: miles per gallon
*
**************************************************************/
#include <iostream>
using namespace std;
int main() {
float tankCapacity; //INPUT - Gas tank capacity in gallons
float mileRange; //INPUT - Range of Miles that can be driven
float MPG; //OUTPUT - MPG car gets
//
cout << "Enter the number of gallons of gas the car can hold." << endl;
cin >> tankCapacity;
cout << "What is the number of miles it can be driven on a full tank?" << endl;
cin >> mileRange;
// Compute MPG
MPG = mileRange / tankCapacity;
//
cout << MPG << " miles per gallon." << endl;
return 0;
}