Design program that read number of hours worked per week

Assignment Help JAVA Programming
Reference no: EM132323594

Programming and Problem Solving Lab Assignment - Selection Structures

Exercise 1: Design and implement a program (name it Youth) that reads from the user an integer values repressing age (say, age). The program prints out the entered values followed by a message as follows: If age is less or equal to 21, the message is "Youth is a wonderful thing. Enjoy.". Finally, the program always prints out the message "Age is a state of mind." Format the outputs following the sample runs below.

Sample run 1:

You entered: 20

Youth is a wonderful thing. Enjoy.

Age is a state of mind.

Sample run 2:

You entered: 25

Age is a state of mind.

Sample run 3:

You entered: 21

Youth is a wonderful thing. Enjoy.

Age is a state of mind.

Exercise 2: The weekly pay for an employee is determined based on the following parameters:

Standard work hours by week is 40 hours.

Hourly pay rate is $10.00 per hour.

Overtime hours are paid at time and a half the rate (that is $15.00 per hour).

Design and implement a program (name it WeeklyPay) that read number of hours worked per week (as integer value), prints out the entered hours, and then prints out the gross earning. Organized your output following these sample runs.

Sample run 1:

You entered 20 hours.

Gross earning is $200.

Sample run 2:

You entered 40 hours.

Gross earning is $400.

Sample run 3:

You entered 50 hours.

Gross earning is $550.

Exercise 3: Design and implement a program (name it GradeReport) that uses a switch statement to print out a message that reflect the student grade on a test. The messages are as follows:

For a grade of 100 or higher, the message is ("That grade is a perfect score. Well done.")

For a grade 90 to 99, the message is ("That grade is well above average. Excellent work.")

For a grade 80 to 89, the message is ("That grade is above average. Nice job.")

For a grade 70 to 79, the message is ("That grade is average work.")

For a grade 60 to 69, the message is ("That grade is not good, you should seek help!")

For a grade below 60, the message is ("That grade is not passing.")

Organized your output following these sample runs.

Sample run 1:

You entered 100

That grade is a perfect score. Well done.

Sample run 2:

You entered 75

That grade is average.

Sample run 3:

You entered 55

That grade is not passing.

Instructions:

1. Programs must be working correctly.

2. Programs must be completed and checked before working the assignment.

3. Programs must be checked by the end of the designated lab session.

Verified Expert

The task of the program is to develop 3 program. The program test the selection structure of java program. The first program requires to receive the age from the user and display message appropriately. The second program requires to enter the number of hours worked by the employee and determine the gross earning. The third program requires to enter the grade mark and display the grade average.

Reference no: EM132323594

Questions Cloud

Focused on the components of good argument : You focused on components of good argument and topic and stance you will take for your argument paper. what are essential elements of a good thesis statement?
Conscious capitalists understand that businesses inherently : Conscious Capitalists understand that businesses inherently exist for reasons beyond profit
Value of things for people seeking to lose weight : Are prices working to tell us about scarcity and the value of things for people seeking to lose weight, buy heroin, rent apartments, donate kidneys
Comparative advantage in global markets : How does a manager can help its company to have a comparative advantage in global markets?
Design program that read number of hours worked per week : CSE 1321L Programming and Problem Solving Lab Assignment - Selection Structures, Kennesaw State University, College of Computing and Software Engineering, USA
Fixed exchange rates and high capital mobility : 1. Under a system of fixed exchange rates and high capital mobility, is monetary policy or fiscal policy better suited for stimulating the economy?
Integer numbers from one to the biggest value : Make a c program using only loops( do not use arrays or functions) that will ask user for 4 integer values and print the smallest two on the screen.
Characteristics features of the organisation : characteristics features of the organisation - Outline any legal governance. management and relationship issues that affect the organisation as a whole
Argument paper using the argument paper outline template : Create an outline of your argument paper using the Argument Paper Outline Template. Complete the following areas of the Argument Paper Outline Template.

Reviews

Write a Review

JAVA Programming Questions & Answers

  Recursive factorial program

Write a class Array that encapsulates an array and provides bounds-checked access. Create a recursive factorial program that prompts the user for an integer N and writes out a series of equations representing the calculation of N!.

  Hunt the wumpus game

Reprot on Hunt the Wumpus Game has Source Code listing, screen captures and UML design here and also, may include Javadoc source here.

  Create a gui interface

Create GUI Interface in java programing with these function: Sort by last name and print all employees info, Sort by job title and print all employees info, Sort by weekly salary and print all employees info, search by job title and print that emp..

  Plot pois on a graph

Write a JAVA program that would get the locations of all the POIs from the file and plot them on a map.

  Write a university grading system in java

University grading system maintains number of tables to store, retrieve and manipulate student marks. Write a JAVA program that would simulate a number of cars.

  Wolves and sheep: design a game

This project is designed a game in java. you choose whether you'd like to write a wolf or a sheep agent. Then, you are assigned to either a "sheep" or a "wolf" team.

  Build a graphical user interface for displaying the image

Build a graphical user interface for displaying the image groups (= cluster) in JMJRST. Design and implement using a Swing interface.

  Determine the day of the week for new year''s day

This assignment contains a java project. Project evaluates the day of the week for New Year's Day.

  Write a java windowed application

Write a Java windowed application to do online quiz on general knowledge and the application also displays the quiz result.

  Input pairs of natural numbers

Java program to input pairs of natural numbers.

  Create classes implement java interface

Interface that contains a generic type. Create two classes that implement this interface.

  Java class, array, link list , generic class

These 14 questions covers java class, Array, link list , generic class.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd