Question: Write a switch . . . case program, use the following sample programs 2 / 2 9 / 2 0 2 4 Class / Homework

Write a switch ...case program, use the following sample programs2/29/2024 Class/Homework, Due: 9/26
Write a if...else program for Weekly Pay Program
Given: hoursWorked =49.55, hourlyRate =2.779, calculate the weeklyPay program.
You are entitled to be paid time-and-a-half for your overtime hours each week in which you work
more than 40 hours.
if (hoursWorked >40)
{
WeeklyPay =
}
else
{
WeeklyPay =
}
Chapter 3 Decision structures
Java Relational Operators: ==,,>,=,>=,!=
Chapter 3: If statement, if...else statements. and nested if statements
// Your Name
// Demo - Smple if syayement
simple if statement
public class Main
{
public static void main(String[] args)
{
int time =20;
if (time ==18)
{
System.out.println("Good day.");
}
}
use input statement to input 2 grades, test 1 and test 2, calculate the average.
if the average =100 or >90, print "your average grade is: A".
. if the average >80, print "your average grade is: B:".
if the average >70, print "your average grade is: C:".
if the average >60, print "your average grade is: D".
else "print F".
 Write a switch ...case program, use the following sample programs2/29/2024 Class/Homework,

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!