Question: 1. Write an if statement that prints out student or non-student based on a boolean variable isStudent Hint: you can use System.out.println () method for

1. Write an if statement that prints out student or non-student based on a boolean variable isStudent Hint: you can use System.out.println () method for outputting the result.

2. Write an if statement that tests a variable that prints out give a raise if the variable workerEvaluation (which can hold 1-5) is greater than 3 AND if the variable yearsWithCompany is greater than 2. Use logical operator && in the boolean expression.

3. Write a multiple if statement that tests a variable that prints out give a raise if the variable workerEvaluation (which can hold 1-5) is greater than 3 OR if the variable yearsWithCompany is greater than 2. Use logical operator || in the boolean expression.

4. Write a multiple-branch if -- else if statement that tests the same variable average and assigns (A,B,C,D or F) to char type variable grade, based on average. (>=90, >=80, >=70, >=60, or < 60)

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!