I am doing this program as practice and who know i might just get this as a exam. i am wondering why i am getting a zero output. I have turn it around and looking thru the codes to see where and why but cannot say for sure. here is my codes. it is just a simple program. any help wud be appreciate.
double hrs, hrlyrate,taxrate=0,total_deduction, gross_salary=0, net_salary=0;
double NIS=0, health_surcharge = 0, rateof_pay =0;
System.out.println("please enter first name");
String firstname = userinput.next();
System.out.println("please enter your last name");
String lastname = userinput.next();
System.out.println("please enter hours worked");
double hrswrk = userinput.nextDouble();
System.out.println("please enter hourly rate ");
hrlyrate = userinput.nextDouble();
hrs = (hrswrk * hrlyrate);
hrs = (hrswrk * rateof_pay);
taxrate = (gross_salary * 0.25);
total_deduction =(NIS + health_surcharge);
net_salary = (gross_salary - total_deduction);
System.out.println("the total deduction is "+total_deduction);
System.out.println("the gross salary is "+gross_salary);
System.out.println("the net salary is "+net_salary);
}


