Question
Using Linux Shell Scripting. - Implement division by 0, with error trapping, using if and while commands, How: a) using ANY editor, append to your
Using Linux Shell Scripting. - Implement division by 0, with error trapping, using if and while commands, How: a) using ANY editor, append to your .sh file commands that will do the following: b) Append your name, current date and time to a NEW file called LinuxResults.txt c) Using two variables: FirstNumber and LastNumber, use a while loop. d) Ask the user to enter the first number. e) Ask the user to enter the second number. f) If the user enters the value 44 for the first or the second number, you must exit this section immediately, g) If the second number is ZERO inform the user that you CAN NOT divide by ZERO, and ask for a correct second number. h) If the second number is NOT a zero, divide FirstNumber by LastNumber and display all numbers on this computation using labels, and append the numbers to the LinuxResults.txt file. example: 4 divided by 1 = 4 3) - Still using Linux Shell Scripting. - Using ANY editor, append to your *.sh file, all the commands needed so that when you execute your .sh file, this file will produce the following: How: - Use a for loop from 1 to 10. - Find the results of calculating each number from (1 to 10 mod 5) + 3. - After the for loop ends, display the average for all previous results and append them to the LinuxResults.txt
Step by Step Solution
3.33 Rating (147 Votes )
There are 3 Steps involved in it
Step: 1
First Part ah binbash my first Script PART 1 read var1 read var2 destdirhom...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