An algorithm for finding the biggest and smallest element in an array can be taken from a variation of the bubble sort algorithm. Bubble sort swaps elements to reorder the array. You can amend it to just find the biggest or smallest. http://en.wikipedia.org/wiki/Bubble_sort
If you're asking for technical help, please be sure to include all your system info, including operating system, model number, and any other specifics related to the problem. Also please exercise your best judgment when posting in the forums--revealing personal information such as your e-mail address, telephone number, and address is not recommended.
Shell Script