Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class Zaulda_Practical
- {
- public static void main(String[] args)
- {
- int undertime, days;
- int nums;
- String n;
- String nem = "";
- Scanner emplo = new Scanner(System.in);
- System.out.println("Type of Employees: ");
- System.out.println("[1] Teaching Permanent (Php1,000.00)");
- System.out.println("[2] Teaching JO (Php600.00)");
- System.out.println("[3] Non-Teaching Permanent (Php700.00)");
- System.out.println("[4] Non-Teaching JO (360.00)\n");
- System.out.println("Select type of Employee(Enter a number only): ");
- nums = emplo.nextInt();
- if(nums == 1)
- {
- nem = "Teaching Permanent";
- System.out.print("'Teaching Permanent'\n");
- System.out.print(" PROCEED BELOW\n");
- nums = 1000;
- }else if(nums == 2)
- {
- nem = "Teachers JO";
- System.out.print("'Teachers JO'\n");
- System.out.print("PROCEED BELOW\n");
- nums = 600;
- }else if(nums == 3)
- {
- nem = "Non-Teaching Permanent";
- System.out.print("'Non-Teaching Permanent'\n");
- System.out.print(" PROCEED BELOW\n");
- nums = 700;
- }else if(nums == 4)
- {
- nem = "Non-Teaching JO";
- System.out.print("'Non-Teaching JO'\n");
- System.out.print(" PROCEED BELOW\n");
- nums = 360;
- }
- System.out.print("\n");
- System.out.print("Enter Employee's Name: \n ");
- n = emplo.next();
- n = n + " " + emplo.next();
- System.out.print("No. of Days Served: ");
- days = emplo.nextInt();
- System.out.print("Under Time: ");
- undertime = emplo.nextInt();
- double earn,tax,deduct,net;
- earn = (nums *days);
- tax = (earn*.03);
- deduct = (undertime*1.25);
- net = (earn - tax - deduct);
- System.out.print("\n");
- System.out.print("Employee's Name: " + n + "\n");
- System.out.print("\nType of Employee: " + nem + "\n");
- System.out.print("\nRate per Day: " +"PhP "+nums + "\n");
- System.out.print("\nEarned for Period: " + "PhP "+ earn + "\n");
- System.out.print("\nTax Deduction: " +"PhP "+ tax + "\n");
- System.out.print("\nAmount Deducted: " +"PhP "+ deduct + "\n");
- System.out.print("\nNet Amount Recieved: " +"PhP "+ net + "\n");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement