I am trying to get this finished, but it seems everything I do to fix it, I get even more errors. Please help me figure this out, I am having a lot of problems with this particular program. Below is my program and build errors, can someone let me know what I am doing wrong?
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
//payroll program3;
/**
*
* @author Melissa
*/
public class PayrollProgram3
{
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
}
}
// main begin payroll application
Scannersc input = new Scanner(System.in);
Employee Employees= new Employee();
double(payRate)
double (hoursWorked)
double (Ratepayed)
while (true)
System.out.println(Enter Employee Name):
Employee.setName(input.next):
if (Employee.Name().ignore("Stop"))
System.out.print ("Enter Employee PayRate);
Employees.setPayRate(input.nextDouble);
while (Employee.payRate() <= 0)
// Loop until valid number is entered for payrate: while (setpayRate < 0.0)
// end while
System.out.print ("Enter # of hours worked: ");
Employee.sethoursWorked(input.nextDouble);
while (Employee.gethoursWorked() <= 0 )
System.out.println ("Invalid amount);
System.out.print ("Please enter hoursWorked: ");
} Employee.sethoursWorked(input.nextDouble());
System.out.printf("%s's weekly earned is:$%.3f\n");
}
/*Employee.getpayRate*/
/* Employee.getName*/
/*Employee.gethours Worked*/
} end while (true)
}end (main)
}//end class PayrollProgram3
init:
deps-jar:
Compiling 1 source file to C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\build\classes
C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\src\PayrollProgram3.java:27: class, interface, or enum expected
Scannersc input = new Scanner(System.in);
C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\src\PayrollProgram3.java:28: class, interface, or enum expected
Employee Employees= new Employee();
C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\src\PayrollProgram3.java:30: class, interface, or enum expected
double(payRate)
C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\src\PayrollProgram3.java:42: unclosed string literal
System.out.print ("Enter Employee PayRate);
C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\src\PayrollProgram3.java:45: class, interface, or enum expected
while (Employee.payRate() <= 0)
C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\src\PayrollProgram3.java:54: class, interface, or enum expected
Employee.sethoursWorked(input.nextDouble);
C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\src\PayrollProgram3.java:55: class, interface, or enum expected
while (Employee.gethoursWorked() <= 0 )
C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\src\PayrollProgram3.java:58: unclosed string literal
System.out.println ("Invalid amount);
C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\src\PayrollProgram3.java:61: class, interface, or enum expected
} Employee.sethoursWorked(input.nextDouble());
C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\src\PayrollProgram3.java:63: class, interface, or enum expected
System.out.printf("%s's weekly earned is:$%.3f\n");
C:\Users\Melissa\Documents\NetBeansProjects\Week4Homework\src\PayrollProgram3.java:64: class, interface, or enum expected
}
11 errors
BUILD FAILED (total time: 0 seconds)