I want to output the annual salary for each employee individually but I'm not sure how. The way it is now it just pops up as one large box.
Any help is much appreciated :)
public static void main(String[] args) {
// TODO code application logic here
String increase,
Salary,
output = "";
double percentIncrease,
AnnualSalary,
AnnualSal;
for(int count = 1; count <= 10; count++ ){
Salary = JOptionPane.showInputDialog("Enter Employee wage " + count );
AnnualSalary = Double.parseDouble(Salary);
increase = JOptionPane.showInputDialog("Enter Percentage Increase for Employee " + count);
percentIncrease = Double.parseDouble(increase);
for(int year = 1; year <= 4; year++ ){
AnnualSalary += ( percentIncrease / 100 )* AnnualSalary;
output += "The new salary for year " + count + " is " + + AnnualSalary + "\n";
}
}
JOptionPane.showMessageDialog(null, output);
System.exit(0);
}
}