Question: QUESTION 3. (10 points) Write a program that reads the temperature and unit from the user and prints a message indicating if it's hot, cool
QUESTION 3. (10 points) Write a program that reads the temperature and unit from the user and prints a message indicating if it's hot, cool or cold. The user may enter the temperature either in Fahrenheit or in Celsius. Below are the intervals, Use nested if-clse statements in your solution. After reading the input, write one compound if-statement that checks if the input is invalid. If it's invalid, terminate the program inmediately using the exit(1); function call (just write exit(1); in your code). You may need to include stdlib.h at the top of the code for this function to work. Below are sample outputs. QUESTION 4. (10 points) Part a) An integer data type is 6-bit. How many combinations does it support? Part b) A 6-bit data type corresponds to unsigned integers. What range of values does it support? Part c) A 6-bit data type corresponds to signed integers. What range of values does it support
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
