結果 : min and max algorithm time complexity