Question
2. Write a complete bash script to convert input centigrade temperature value to Fahrenheit temperature. The conversion formula is C x 9/5 + 32 =
2. Write a complete bash script to convert input centigrade temperature value to Fahrenheit temperature.
The conversion formula is C x 9/5 + 32 = F
You must loop thru the script until the user enters 1 or 0 (1 = continue, 0 = exit)
Here is a screen dump of an actual run.
$ ./celsius_to_fahrenheit.sh
Celsius to Fahrenheit Converter
===============================
What is the temperature in Celsius?34
Celsius 34 is Fahrenheit 93
Do you want to continue?(1 = yes, 0 = no) 1
Celsius to Fahrenheit Converter
===============================
What is the temperature in Celsius?67
Celsius 67 is Fahrenheit 152
Do you want to continue? (1 = yes, 0 = no) 1
Celsius to Fahrenheit Converter
===============================
What is the temperature in Celsius? 40
Celsius 40 is Fahrenheit 104
Do you want to continue? (1 = yes, 0 = no)
0
Thank You. BYE!
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