Question
Today we are thinking about temperature! You are going to write a program to determine whether or not a person has a fever. A normal
Today we are thinking about temperature! You are going to write a program to determine whether or not a person has a fever. A normal temperature can be between 98.4F 98.9F. We will assume that all temperatures will be at least 98.4F and just worry about whether or not the temperature is too high. If the temperature is normal, we will output Your temperature is normal. Otherwise, the program will output You have a temperature! Details of your program are defined below. Hint: We learned about if/else statements in class today! Details Input The program takes in the following input: a floating-point variable named bodyTemperature, representing the temperature of a person in degrees Fahrenheight (F). Note that input is read in for you and that the value taken in as input is output so that you know what was read in. Processing You will check if the temperature is above 98.9F. Output If bodyTemperature is above 98.9, the program will output: You have a temperature! Otherwise, it will output: Your temperature is normal. Sample input/output:
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started