Billionaire Donaldio Trumpola has hired you to help him run his many businesses. He has so many staff members in so many different companies that he is losing track of them all. What he would like you to do, is write a program, that he can use to enter in the information about his companies. He will want to input the following information for each department:
Cost Per Employee:
Below is the data he would like you to enter (you didn't think he would enter it himself did you?) Write your program to handle the amount of information that needs to be inputted. You do not need to use a loop, you can simply have multiple requests to ".readLine()" .
Finally, Donaldio would like your program to use all the information inputted to find out if he has made any money, or if he is bankrupt. Calculate the cost to run each department, and compare that to the sales for the department, come up with a total, and present all your numbers in a nice output that has been formatted - using the technique you have learned in the notes - to show money with two decimal places, comma's and a dollar sign. In the output you should present the statistics for each department, and the statistic for all departments.
Here is the Data:
Department Name: Cool Casino
# of Employees: 543
Cost Per Employee: 0.75
Department Name: Trumpola Burgers
# of Employees: 43
Cost Per Employee: 19.725
Department Name: Donoldio Clothing for Cats
# of Employees: 4.0001
Cost Per Employee: 5.233
Department Name: Trumpola Leaning Tower
# of Employees: 1003
Cost Per Employee: 1.2123
Bonus: Use a loop to ask how many departments Donaldio would like entered and then loop through that many requests!
I have written down the code:
public class Business
public static void main (Stringargs) throws IOException
in = new BufferedReader(new InputStreamReader(System.in));
department = in.readLine();
System.out.println("Department Name: "+department);
em = new BufferedReader(new InputStreamReader(System.in));
employees = in.readLine();
co = new BufferedReader(new InputStreamReader(System.in));
System.out.println("Cost per Employee:");
cost = in.readLine();
System.out.println("Cost per Employee: "+cost);
sa = new BufferedReader(new InputStreamReader(System.in));
sales = in.readLine();
What should I do next?? I can input the information given above, however, I need to type "java Business" in order to enter the 2nd information. Can I do it within one program??