Question: Java program Q5. What is the output of the following code if number is 14, 15, or 30? if (number % 2-0) System.out.println if (number

 Java program Q5. What is the output of the following code

Java program

Q5. What is the output of the following code if number is 14, 15, or 30? if (number % 2-0) System.out.println if (number % 2-0) System.out-println numberis even") Cnumber is even) if (number % 5 ". O) System.out.println else if (number % S "" 0) System,out printin (number s multiple of s numberis multiple of (bi Q6. Write conditional expression that returns-1 or 1 randomly. Q7. Write an if statement that assigns tox if y is greater than 0.? Q8. W rte an if statement that increases pay by 3% if score is greater than 90, otherwise increases pay by 1%? 09. Rewrite the following conditional expressions using if-else statements. a. score (x> 10)? 3 scale: 4 * scale; b. System.out.println((number % 3.: 0)?i:j)

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!