結果 : find the largest and smallest element in an array using javascript