(Solved) : 1 Using Switch Statement Employee Type P P Display Part Time Employee Screen Employee Type Q30110158 . . .
1. Using a switch statement
If the employee type is P or p, then display “Part- timeemployee” on the screen
If the employee type is F or f, then display “Full-timeemployee” on the screen
If the employee type is T or t, then display “Temporaryemployee” on the screen
If the employee is none of the above, then display “Invalidemployee type” on the screen
2. Using an single individual distinct ifstatement (not a nested if):
If the employee makes $50 an hour or more, and is also afull-time employee, print out to the screen “You must be a Javaprogrammer!”
3. Using a single if-else-if statement:
If the employee type is part-time, and the hours worked is 35hours or more, then print out to the screen “You worked like aFull-time employee”
If the employee type is full-time, and the hours worked is lessthan 25, then print out to the screen “Are you sure you’re not apart-time employee?”
Else print out to the screen “Have a nice day!”
4. Using a while loop structure:
If the total hours worked is less than 0 or greaterthan 280, then print out “That’s not possible, please tryagain!” to the screen. Prompt the user to enter the total hoursagain (inside the loop)
Allow up to 3 total invalid attempts for the user to enter thecorrect number of hours. After the 3rd attempt, print out “You areFired!” and exit the program (or start program over)
5. Using a do-while loop structure:
After the program completes, ask the user “Do you want to startthe program over again? (Enter Yes or No)”.
If the user enters “Yes” as a String literal (in any casemeaning they can enter Yes, yes, yeS, yEs, YES, or YEs and itshould still work), then the program should start over again fromthe beginning
Expert Answer
Answer to 1 Using Switch Statement Employee Type P P Display Part Time Employee Screen Employee Type Q30110158 . . .
OR