Write a program that prompts the user to enter the name, the number of children, and...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Write a program that prompts the user to enter the name, the number of children, and the basic salary of an employee. The program will then: • Calculate the bonus: bonus = number of children * $25 • Calculate the new salary: new salary = salary + bonus Apply a tax of 10% and find the paid salary: paid salary = new salary * (1 – tax) The program will then display all the information needed as shown in the sample run below Sample Run: Enter the name of the employee: Jamal Enter the number of children of the employee: 4 Enter the salary of the employee (in $): 1500 The calculated bonus is $100 for 4 children. The new salary is $1600.0 The paid salary for Jamal is $1440.0 Write a program that prompts the user to enter the name, the number of children, and the basic salary of an employee. The program will then: • Calculate the bonus: bonus = number of children * $25 • Calculate the new salary: new salary = salary + bonus Apply a tax of 10% and find the paid salary: paid salary = new salary * (1 – tax) The program will then display all the information needed as shown in the sample run below Sample Run: Enter the name of the employee: Jamal Enter the number of children of the employee: 4 Enter the salary of the employee (in $): 1500 The calculated bonus is $100 for 4 children. The new salary is $1600.0 The paid salary for Jamal is $1440.0
Expert Answer:
Answer rating: 100% (QA)
import javautilScanner public class Main public static void mai... View the full answer
Related Book For
Introduction to Java Programming, Comprehensive Version
ISBN: 978-0133761313
10th Edition
Authors: Y. Daniel Liang
Posted Date:
Students also viewed these programming questions
-
Write a program that prompts the user to enter the name of an ASCII text file and displays the frequency of the characters in the file.
-
Write a program that prompts the user to enter three strings. Compare the String objects lexicographically and print the middle-valued string. For example, if the three strings were "abcd", "wxyz",...
-
Write a program that prompts the user to enter a Social Security number in the format DDD-DD-DDDD, where D is a digit. Your program should check whether the input is valid. Here are sample runs:...
-
Every real number is either a/an number or a/an_______ number.
-
Ramsay Mfg. Co. has an active internal audit department that has a major objective to ensure compliance with company policies and to identify ways in which an organization can improve its operational...
-
Draw the graph of the NRZ-L scheme using each of the following data streams, assuming that the last signal level has been positive. From the graphs, guess the bandwidth for this scheme using the...
-
Consider the assembly of three components shown in Figure 9-22. The tolerances for these three components are given in Table 9-8. Assume that the tolerances on the components are independent of each...
-
FARO Technologies, whose products include portable 3D measurement equipment, recently had 17 million shares outstanding trading at $42 a share. Suppose the company announces its intention to...
-
Johnson Enterprises uses a computer to handle its sales invoices. Lately, business has been so good that it takes an extra 3 hours per night, plus every third Saturday, to keep up with the volume of...
-
Explain how personal selling can help solve the problem of information overload.
-
DEF Enterprises has reported the following data for the year 2023: Revenue: $600,000 Direct Costs: $350,000 Overhead Costs: $100,000 Selling Expenses: $70,000 Loan Interest: $20,000 Tax Provision:...
-
How do cultural differences influence the manifestation and expression of emotional intelligence across diverse global contexts, and what strategies can individuals and organizations employ to...
-
How could Google Leadership have communicated as ethical defense for DragonFly?
-
How can leadership development programs be tailored to cultivate a culture of accountability and empowerment within the organization ?
-
Do you believe someone with an authoritarian style of leadership can be a transformational leader?
-
What role does leadership play in shaping and sustaining organizational culture, and how do different leadership styles and behaviors impact cultural alignment, employee morale, and organizational...
-
A firm's shareholders believe that if its current debt (2.5 million) were replaced by equity then earnings per share would increase. Assume the debt has a 10% interest rate, the tax rate is 45%,...
-
Audrey purchases a riding lawnmower using a 2-year, no-interest deferred payment plan at Lawn Depot for x dollars. There was a down payment of d dollars and a monthly payment of m dollars. Express...
-
Programming Exercise 3.17 gives a program that plays the scissor-rock-paper game. Revise the program to let the user continuously play until either the user or the computer wins more than two times...
-
Modify the ClockPane class in Section 14.12 to draw the clock with more details on the hours and minutes, as shown in Figure 14.52a. 12 11 10 22:44:37 (a) 3.
-
Listing 15.17 BallPane.java using a thread to animate bouncing ball movements. Listing 1 import javafx.animation.KeyFrame; 2 import javafx.animation.Timeline; 3 import...
-
The Frohman culture model includes which of the following cultural types? a. Paternalistic b. Individualized c. Collaborative d. All of the above
-
When appointed, a project manager has formal power conveyed to him/her. Based on the PMs role, the formal power could include ________ power. a. Charisma and Reward b. Reward and Coercive c. Reward...
-
Understanding the alignment between the organizations broader goals and what your own project is meant to deliver is a reflection of: a. Leadership Maturity b. Strategic Awareness c. Executive...
![Mobile App Logo](https://dsd5zvtm8ll6.cloudfront.net/includes/images/mobile/finalLogo.png)
Study smarter with the SolutionInn App