Question: Question 5 (TCO 2) The next field in a node of a linked list is also referred to as the _____. node link initial address
Question 5
(TCO 2) The next field in a node of a linked list is also referred to as the _____.
| node |
| link |
| initial address |
| data portion |
Flag this Question
Question 6
(TCO 2) _____ can be traversed backward.
| Doubly linked lists |
| Heaps |
| Stacks |
| Binary search trees |
Flag this Question
Question 7
(TCO 2) The node of a doubly linked list contains _____.
| one pointer field and one data field |
| one pointer field and two data fields |
| two pointer fields and one data field |
| two pointer fields and two data fields |
Flag this Question
Question 8
(TCO 2) In a _____, the last node points to the first node.
| array-based queue |
| array-based circular queue |
| linked list |
| circular linked list |
Flag this Question
Question 9
(TCO 3) When you add an item to a stack, you place it
| on the bottom. |
| on the top. |
| in the middle. |
| it doesnt matter where. |
Flag this Question
Question 10
(TCO 3) What is the stack operation implemented in the following function? The variable top represents the stack top. void operation(itemType t) { list[top] = t; top++; }
| getLength |
| push |
| remove |
| The constructor of the class Stack |
Flag this Question
Question 11
(TCO 3) Consider the following program fragment. Stack s; s.push(1); s.push(2); s.push(3); s.pop(); cout
| 0 |
| 1 |
| 2 |
| 3 |
Flag this Question
Question 12
(TCO 3) The _____ is a data structure that satisfies the first in, first out (FIFO) principle.
| linked list |
| array-based list |
| stack |
| queue |
Flag this Question
Question 13
(TCO 4) Which of the following functions has a constant growth rate?
| n |
| n2 |
| n log n |
| 1 |
Flag this Question
Question 14
(TCO 4) A(n) _____ is a finite collection of steps used to solve a problem.
| function |
| algorithm |
| object |
| class |
Flag this Question
Question 15
(TCO 4) The big O asymptotic notation is used to express the _____.
| solutions of a linear equation |
| number of clock cycles per instruction |
| running time of an algorithm |
| number of lines of a program |
Flag this Question
Question 16
(TCO 4) The following function returns the _____ of the array elements. int mystery(int a[], int n) { int x=a[0]; for (int i=1; i
| maximum |
| minimum |
| middle element |
| pivot |
Flag this Question
Question 17
(TCO 5) Which of the following is not a search algorithm or technique?
| Sequential search |
| Binary search |
| Linear search |
| Quadratic search |
Flag this Question
Question 18
(TCO 5) Why can't a binary search be applied on the list below? 17, 22, 31, 19, 39, 43, 16
| The list is too small. |
| The list is not sorted. |
| The size of the list is not a power of 2. |
| A binary search can be applied on the list as it appears. |
Flag this Question
Question 19
(TCO 5) When designing a hash function, we try to _____ the number of collisions.
| maximize |
| minimize |
| double |
| increment |
Flag this Question
Question 20
(TCO 5) In open addressing, data is stored in a(n) _____.
| class |
| queue |
| array |
| linked list |
Flag this Question
Question 21
(TCO 6) In the following binary tree, the root node is _____. 
| 61 |
| 26 |
| 14 |
| 18 |
Flag this Question
Question 22
(TCO 6) In the following binary tree, the height of the node with value 41 is _____. 
| 1 |
| 2 |
| 3 |
| 4 |
Flag this Question
Question 23
(TCO 6) In a binary search tree the _____ is stored in the leftmost node of the tree.
| smallest value |
| greatest value |
| median |
| mean |
Flag this Question
Question 24
(TCO 6) In a binary search tree, the key in the _____ node is larger than the key in the root node.
| right |
| bottom |
| root |
| header |
Flag this Question
Question 25
(TCO 7) To represent a graph in a program, use a(n) _____.
| array list |
| adjacency matrix |
| stack |
| binary tree |
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
