public/subjects/devops/comparator
miguel 04e90aa8be fix(comparator):fixing the test
improving error message in the solution
add readme info about error message
2023-01-13 15:21:24 +00:00
..
README.md fix(comparator):fixing the test 2023-01-13 15:21:24 +00:00

README.md

comparator

Instructions

Create a script comparator.sh which will accept only two numbers as arguments and it will verify if the first given argument is bigger, smaller or equal than the second given argument. You must print the output like the example in usage.

Usage

$ ./comparator.sh 6 14
6 < 14
$ ./comparator.sh 29 3
29 > 3
$ ./comparator.sh 12 12
12 = 12
$ ./comparator.sh  8 9 9
Error: The script only works with two arguments!
$ ./comparator.sh  8 s
Error: Only two numeric arguments are acceptable!
$ ./comparator.sh  8
Error: The script only works with two arguments!
$

You have to use Man or Google to know more about commands flags, in order to solve this exercise! Google and Man will be your friends!