Advertisement
STANAANDREY

lab1

Feb 19th, 2024
1,164
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.21 KB | None | 0 0
  1. #!/bin/bash
  2.  
  3. if test "$#" -ne 3; then
  4.     echo "invalid args"
  5.     exit 1
  6. fi
  7.  
  8. maxi=$1
  9.  
  10. if test $2 -gt $maxi; then
  11.     maxi=$2;
  12. fi
  13.  
  14. if test $3 -gt $maxi; then
  15.     maxi=$3;
  16. fi
  17.  
  18. echo "maximum=$maxi"
  19.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement