阿摩線上測驗 登入

試題詳解

試卷:101年 - 101 國立交通大學_碩士班考試入學試題_資訊聯招:資料結構與演算法#113301 | 科目:研究所、轉學考(插大)-資料結構

試卷資訊

試卷名稱:101年 - 101 國立交通大學_碩士班考試入學試題_資訊聯招:資料結構與演算法#113301

年份:101年

科目:研究所、轉學考(插大)-資料結構

(31) Consider the following algorithm. Algorithm Sort(A, n)
Input: Array A containing n different integer values.
Out: Array A sorted in increasing order of values.
Which of the following instructions must be inserted at the point marked (*) so that the algorithm correctly sorts the values stored in A in increasing order of values?
(A) for j ← 0 to n - 1 do if A[j] > A[m] then m ← j
(B) for j ← i+1 to n - 1 do if A[j] > A[m] then m ← j
(C) for j ← 0 to i - 1 do if A[j] > A[m] then m ← j
(D) for j← i+ 1 to n -1 do if A[j] < A[m] then m ← j
(E) for j ← O to n -1 do if A[j] < A[m] then m ← j

正確答案:登入後查看

詳解 (共 2 筆)

推薦的詳解#7101511
未解鎖
1. 題目解析 題目提供了一個排序算法...
(共 886 字,隱藏中)
前往觀看
0
0
推薦的詳解#7101512
未解鎖
題目解析 這道題目的目的是要找出在一個...
(共 1054 字,隱藏中)
前往觀看
0
0