//Dione Torrevillas                 CS1A                 Chapter 5, P. 294, #3
//
/**********************************************************************
 *
 * OCEAN LEVELS
 *
 * This program displays the amount the ocean level will rise
 * each year for the next 25 years. The ocean level is assumed
 * to rise 1.5 millimeters each year.
 *
 * Computation is based on the formula:
 * Ocean Rise = Year x 1.5 millimeters
 *
 * INPUT
 *   None
 *
 * OUTPUT
 *   oceanRise    : Total ocean level rise for each year
 *
 **********************************************************************/

#include <iostream>
#include <iomanip>
using namespace std;

int main()
{
    const double RISE_PER_YEAR = 1.5;  //CALC   - Rise each year in millimeters
    int year;                          //CALC   - Loop counter
    double oceanRise;                  //OUTPUT - Total rise in millimeters

    //
    // Output Table Heading
    //
    cout << "Year\tOcean Level Rise (mm)" << endl;
    cout << "-----------------------------" << endl;

    //
    // Compute and Output Ocean Rise
    //
    for (year = 1; year <= 25; year++)
    {
        oceanRise = year * RISE_PER_YEAR;

        cout << year << "\t"
             << fixed << setprecision(1)
             << oceanRise << endl;
    }

    return 0;
}