This is something you do every day, probably. Compare things. And then, based on whatever your objective is, you ferret out the one object that meets your requirements.
This is a really simple script, assuming input on the command line of any number of numbers, separated by spaces. When it's done, it will print out the largest number of the bunch.
Not super exciting, but fundamental and applicable to lots of things, depending on what you want to compare. Later on, I'll post the equivalent alpha version of this numeric scriptlet
This work is licensed under a
Creative Commons Attribution-Noncommercial-Share Alike 3.0 United States License
# 2007 - Mike Golvach - firstname.lastname@example.org
# Creative Commons Attribution-Noncommercial-Share Alike 3.0 United States License
for x in $@
if [ $x -gt $highest_number ]
print "Highest Number is $highest_number"
Yes, today is my day of rest ;)
linux unix internet technology
Wednesday, October 24, 2007