By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,131 Members | 1,425 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,131 IT Pros & Developers. It's quick & easy.


P: 2
I Need help writing a program that will process payroll for small company with 26 employess, needs to store all employee name in sequential file along with address info, pay rate, number of dependents, martial status and a dollar amount which is a deduction for the company 401k plan.

part one of the program allows one to add employee to the sequential file. part two of the program reads the sequential file, and for the each employee, ask for the hours worked for the pay periof and calculated the pay and displays the info on the screen, part three of the program reads the sequential file and displays the info to the screen in a report format

program must have at least 3 functions, the switch statement , the repetition structure and the decision structure. program should open giving the operator choices for the three options or close program, when an option is selected and completed the menu should display again and allow the user to make another choice or the choice to quit

this is what i have so far, im not the best in C++ so i really need some help
#include <iostream>
#include <iomanip>
#include <string>
#include <fstream>

using namespace std;
//const int maxNuberofEmployee = 26;
//void getEmployeeDAta (ifstream& infile, employeeName employeeList [], int numberofEmployee);
//void printpayReports(ofstream& outfile, employeeName employeeList[], int numberofEmployee, double payRate);

int main()
string fName;
string lName;
string address'
int noOfDependents;
char mstatus;
double deduction;
int count;
count = 0;
cout << "Enter the First Name: ";
cin >> fName;
cout << endl;
cout << "Enter the Last Name;
cin >> lname;
cout << endl;
cout << "Enter the Address: ";
cin >> address;
cout << endl;
cout << "Enter M(arried) or S(ingle): ";
cin >> mstatus;
cout << endl;
cout << "How much you want us to deduct for 401k plan? ";
cin >> deduction;
cout << endl;
count = count + 1;
while (count <= 26);
NOW WHERE DO I GO FROM HERE SOMEONE PLEASE .........................HELP ME!!!!!!!!!!!!!!!!!
Dec 1 '06 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.