Find minimum integer in collection when it is the first element.
Find minimum integer in collection when it is the last element.
Find maximum integer in collection when it is the first element.
Find maximum integer in collection when it is the last element.