Question: Q1: Using your own coding example, or modifying the coding examples in our lectures on selections, create a working Java programme that: First receives a

Q1: Using your own coding example, or modifying the coding examples in our lectures on selections, create a working Java programme that: First receives a temperature value from the user from console and assigns it to a variable of an appropriate data type. Write a sequence of if-then-elseif statements to check if temperature of the day is greater than 90, 80, 70, or 60, and display appropriate message relevant to the temperature of the day as follows: i) if temperature of the day is greater than 90 display on the console message BURNING HOT ii) if temperature of the day is greater than 80 and less than 90 display on the console message HOT ii) if temperature of the day is greater than 70 and less than 80 display on the consoled message PLEASANT iv) if temperature of the day is greater than 60 and less than 70 display on the console message COLD If no condition is TRUE, set the default ELSE to display on the console the following message: TEMPERATURE NOT AVAILABLE.

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!