結果 : in an array print the second smallest and second largest element in java