 <p>the thing about the max being assigned as -999, max is meant to check the maximum values, and min is checking the minimum values, so its suppose to ask at each position if the column indices if even then if it is, its asking if the greatest value (which are usually positive) bigger than -999, and if they would be less than 1000, and so on.. until i get maximums and minimums, because -2000 is actually smaller than -999 so if i entered that, its suppose to be kept in minimum not max ^_^</p>