Question: Need this code in C# and display output public class Employee //Method for employee information private void EmployeeInfo(string firstName, string lastName) string empFul1Nae firstNamelastNane; Console.WriteLine(Employee's
public class Employee //Method for employee information private void EmployeeInfo(string firstName, string lastName) string empFul1Nae firstNamelastNane; Console.WriteLine("Employee's Nane\t\t\t: {e)",enpFul?Name); //Method for hourly employee private void EmployeeHourly (double hoursWorked, double hoursRate) double regularPay-8; double overtimePay e if (hoursworked 48) //checks if employee work overtine regularPay hoursRate hoursworked; if (hoursWorked> 48) overtimePay(hoursWorked 4) 1.5hoursRate; regularPay overtimePay (4hoursRate); Console.WriteLine( Employee's weekly incomelt: se,regularPay) //Method for monthly employee private void EmployeeMonthly (double monthlyRate) double regularPay month lyRate * 12; Console.WriteLine( Employee's monthly incomelt: s(,regularPay) //Method for monthly employee private void EmployeeYearly(double yearlyRate) double regularPay yearlyRate; Console.Writeline( Employee's yearly inconet: S(0, regularPay); //Display Employee Info public void DisplayEmployeeInfo() string empFirstName, enplastName; double empHourRate-8, empHoursworked-e; //for hourly enployee double empMonthlyRate8 double empYearlyRate 8 //for monthly employee //for yearly employee Console.Write( Enter Enployee first name\t:) empFirstName Console.ReadLineO: Console.Write( Enter Enployee last nanet: espLastNameConsole.ReadLine(); //prompts user to make a choice for employee income Console.Writeline( Employee incone:"); Console.Writeline( Assuming employee is hourly rated"); Console.Write( Enter Employee hourly ratelt:); eepHourRate Convert.ToDouble(Console.ReadL ine)) Console.Write( Enter Employee hours worked\t:) empHoursWorked Convert. Tobouble(Console. ReadLine()); //Assuming Employee is Monthly rated
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
