/*********************************************
 * AUTHOR		: Cecilia Rangel
 * PROJECT #1	: BASIC INPUT/OUTPUT
 * CLASS		: CSC5
 * SECTION		: MW - 2:20 - 5:30pm
 * DUE DATE		: 9/21/26
 **********************************************/

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

/***********************************************************************
 *
 * COMPUTE RETROACTIVE PAY
 * _____________________________________________________________________
 * this program accepts as user input, as in employee
 * name, current salary and percent increase and computes
 * a new annual salary, new monthly salary and retroactive pay
 * due. the program will loop three times, prompting the user for the
 * Appropriate input and displaying the computed values for the given input.
 *
 * computations are based on the assumption that the input values are effective
 * on January 1 and calculations are affective July 1
 * _____________________________________________________________________
 *INPUT
 *	nameFull		: Employee's full name
 *	salleryCurrent	: Current annual salary
 *	percent			: Percent increase due
 *
 *OUTPUT
 *	salaryNew		: New salary after applying increase
 *	salaryMonthly	: new monthly salary
 *	retroactivePay 	: retroactive pay due
 *
 ***********************************************************************/
int main ()
{
	const int MONTHS = 12;
	const int RETRO_MONTHS = 6;

	std:: string name;
	float salaryCurrent;
	float percentIncrease;
	float salaryNew;
	float salaryMonthly;
	float retroactivePay;
	cout << fixed; 

	for (int count =1; count <= 3; count++) {
		cin >> salaryCurrent;
		cin >> percentIncrease;
		cin.ignore();
		getline(cin, name);
		salaryNew = (1 + percentIncrease) * salaryCurrent;
		salaryMonthly = salaryNew / MONTHS;
		retroactivePay = (salaryMonthly - (salaryCurrent / MONTHS)) * RETRO_MONTHS;


		cout << "\n Employee name: " << showpoint << name;
		cout << "\n New salary: $" << setprecision(2) << showpoint << salaryNew;
		cout << "\n Monthly salary: $" << setprecision(2) << showpoint << salaryMonthly;
		cout << "\n Retroactive Pay: $" << showpoint << retroactivePay;
	}
return 0;
}