Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Write a shell script that accepts no command line arguments. The script reads three integers from the standard input. If the three integers are in
Write a shell script that accepts no command line arguments. The script reads three integers from the standard input. If the three integers are in an ascending order; it prints the median number and quits If the three numbers are not in an ascending order, it displays NO and proceeds to read three integers and repeat until three ascending numbers are read; then it displays the median number and quits.
for example CPU % q22.sh
3 3 4 NO
3 6 2
NO
3 4 5
4
CPU%
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