卷別
資料結構與演算法(A)
選擇國立臺灣大學 2021 · 考試 · 第 8 題
考科資料結構
(5 points) 承上題(陣列 與索引 初值皆 0,僅能由 存取)。If functions and are changed as following:
f(x):
A[q] ← x
q ← q + 1
g():
x ← A[p]
p ← p + 1
return x
Which data structure is operated by those functions?
- (A)Queue
- (B)Stack
- (C)Hash
- (D)Heap