Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- class Boss {
- static void Main() {
- Console.WriteLine("Enter your employee ID : ");
- int id = Convert.ToInt32(Console.ReadLine());
- switch(id)
- {
- case 1001:
- Console.WriteLine("Employee name : Jose Rizal");
- Console.WriteLine("Employee Position : Manager");
- Console.WriteLine("Employee Rate : 750 /hr");
- Console.WriteLine("Late : ");
- int late = Convert.ToInt32(Console.ReadLine());
- Console.WriteLine("Absencess : ");
- int absent = Convert.ToInt32(Console.ReadLine());
- Console.WriteLine("Overtime : ");
- int overtime = Convert.ToInt32(Console.ReadLine());
- Console.WriteLine("Undertime : ");
- int undertime = Convert.ToInt32(Console.ReadLine());
- int hours = 248;
- double late1 = late * 1/60;
- int total1 = absent*8;
- double undertime1 = undertime * 1/60;
- double final_total = hours - (total1 + overtime + late1 + undertime1);
- Console.WriteLine("No. of hours Reduced : " + final_total);
- int Rate = 750;
- double salary = final_total * Rate;
- Console.WriteLine("Total Salary : " + salary);
- break;
- case 1002:
- Console.WriteLine("Employee name : Andress Bonifacio");
- Console.WriteLine("Employee Position : Supervisor");
- Console.WriteLine("Employee Rate : 650 /hr");
- break;
- case 1003:
- Console.WriteLine("Employee name : Gabriela Silang");
- Console.WriteLine("Employee Position : Clerk");
- Console.WriteLine("Employee Rate : 350 /hr");
- break;
- }
- }
- }
- Previous
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement