$29
1. Get Section_5_14_3.java and load it in your IDE. Go to section 5.14.3 and complete the following 11 exercises: #20 to #30 inclusive. Code the answers in java in the provided file.
2. Go to section 5.14.4 and complete the following 8 exercises: #31 to #38 inclusive. Provide answers in a text file.
3. Write a program that calculates the area of the following two figures:
a square of side 0.666666667
and a rectangle of sides 4.0 and 1.0/9.0 . Test the two calculated areas for equality and discuss your result.
4. Write a program that reads a temperature as a whole number from the keyboard and outputs a "probable" season (winter, spring, summer, or fall) depending on the temperature:
if the temperature is greater than 110 or less than -5, than you should output that the temperature entered is outside the valid range
if the temperature is greater than or equal to 90, it is probably summer
if the temperature is greater than or equal to 70 and less than 90, it is probably spring
if the temperature is greater than or equal to 50 and less than 70, it is probably fall
if the temperature is less than 50, it is probably winter
Use the following flow of the program:
if input is out of range
{
give an error
}
else
{
using cascading if statement compute the value of the season outside of the if block print the result
}
https://cilearn.csuci.edu/courses/5532/assignments/61967 1/2
12/14/2020 L5a
https://cilearn.csuci.edu/courses/5532/assignments/61967 2/2