In this article I will show you an application that I wrote in C++ I called it Payroll System in C++ with Colors. In this application I'm Using Dev C++ as my C++ compiler it is an open source program that is very good in writing C++ codes and what is important it is free. Below is the list of colors that can be use using C++.
Color Codes:
0 = Black
1 = Blue
2 = Green
3 = Aqua
4 = Red
5 = Purple
6 = Yellow
7 = White
8 = Gray
9 = Light Blue
A = Light Green
B = Light Aqua
C = Light Red
D = Light Purple
E = Light Yellow
F = Bright White
If you have some questions please send me an email at jakerpomperada@yahoo.com and jakerpomperada@gmail.com. People here in the Philippines who wish to contact me can reach me at my mobile number 09173084360.
Sample Program Output
Program Listing
#include <iostream>
#include <iomanip>
#include <stdlib.h>
using namespace std;
main(){
string employee_name,position;
float daily_rate=0.00,tax=0.00,sss=0.00,pag_ibig=0.00;
float solve_salary=0.00, net_pay=0.00,total_deductions=0.00;
int no_days_work=0;
system("COLOR 69");
cout << "\t ===== EMPLOYEE'S PAYROLL SYSTEM =====";
cout << "\n\n";
cout << "Enter Employees Name :=> ";
getline(cin,employee_name);
cout << "Enter Employees Position :=> ";
getline(cin,position);;
cout << "Enter Daily Salary Rate :=> $ ";
cin >> daily_rate;
cout << "Enter Number of Day's Worked :=> ";
cin >> no_days_work;
solve_salary = (daily_rate * no_days_work);
cout << "\n\n";
cout << "Your Gross Pay is $ " << fixed
<< setprecision(2) <<solve_salary << ".";
cout << "\n\n";
cout << "Enter Employee's Tax :=> $ ";
cin >> tax;
cout << "Enter Employee's SSS Contribution :=> $ ";
cin >> sss;
cout << "Enter Employee's PAG-IBIG Contribution :=> $ ";
cin >> pag_ibig;
total_deductions = (tax+sss+pag_ibig);
net_pay = (solve_salary - total_deductions);
cout << "\n\n";
cout << "Total Deductions $ " << fixed
<< setprecision(2) <<total_deductions << ".";
system("COLOR A9");
cout << "\n\n";
cout << " ====== PAYROLL REPORT ======";
cout << "\n\n";
cout << " NAME : " << setw(5)<< employee_name
<<setw(8) << " POSITION : " << setw(5)<< position
<< setw(8) << " NET PAY $ " << setw(5)<< net_pay;
cout << "\n\n";
system("pause");
}
please create management system salary employee using C/C++ Languages
ReplyDeleteplease also create Net income
ReplyDelete