2009数据结构英文试卷a及答案----new2009数据结构英文试卷a及答案----new2009数据结构英文试卷a及答案----new2009数据结构英文试卷a及答案----new.doc
文本预览下载声明
Final examination
2009 Fall
Data Structure and Algorithm Design
Class: Student Number: Name: Teacher
No. 1 2 3 4 5 6 7 8
9 Total Mark 1.Single-Choice(20 points)
(1) Consider the following definition of a recursive function ff.
int ff( int n )
{ if( n == 0 ) return 1;
return 2 * ff( n - 1 );
}
If n 0, what is returned by ff( n )?
(a) log2 n (b) n2 (c) 2n (d) 2 * n
(2) An input into a stack is like 1,2,3,4,5,6. Which output is impossible? .
a. 2,4,3,5,1,6 b.3,2,5,6,4,1 c.1,5,4,6,2,3 d.4,5,3,6,2,1
(3) Which of the following data structures uses a Last-in, First-out policy for element insertion and removal?
(a) Stack (b) Tree (c) Hash table (d) Queue
(4) If deleting the ith key from a contiguous list with n keys, keys need to be shifted left one position.
a. n-i b. n-i+1 c. i d. n-i-1
(5) Sorting a key sequence(28,84,24,47,18,30,71,35,23), its status is changed as follows.
23,18,24,28,47,30,71,35,84
18,23,24,28,35,30,47,71,84
18,23,24,28,30,35,47,71,84
The sorting method is called
(a).select sorting (b).Shell sorting
(c).merge sorting (d).quick sorting
(6) The number of keyword in every node except root in a B- tree of order 5 is _ _ at least
a. 1 b. 2 c. 3 d. 4
(7) When sorting a record sequence with multiple keys using Least Significant Digit method, the sorting algorithm used for every digit except the least significant digit .
a. must be stable b. must be unstable c. can be either stable or unstable
(8) In the following four Binary Trees, is not a complete Binary Tree.
a b c d
(9) The maximum number of nodes on level i of a binary tree is .
a.2i-1 b. 2i c.2i d.2i-1
(10) If the Binary Tree T2 is transformed from th
显示全部