The benefit of using a linked list is to ____ large amounts of data
A -
Integer
B -
Join together
C -
Float
D -
None of the above
2-
The following function.
static int ttt(int x, int y) {
if (x % y = = 0)
return x/y + 2;
else
return x – ttt(y, x + 1);
}
Determine the output of the following statement.
println(ttt(7, 3));
A -
8
B -
None of the others answers
C -
10
D -
6
3-
The picture is presented for one step of:
A -
Quick Sort
B -
Selection Sort
C -
Bubble Sort
D -
Insertion Sort
4-
the number of swappings needed to short the numbers 8 ,22, 7, 9, 31, 5, 13 in
ascending order using bubble sort is
A -
12
B -
13
C -
14
D -
15
5-
the way a card game player arranges his cards as he picks them up one by one, is an
example of
A -
merge sort
B -
selection sort
C -
insertion sort
D -
bubble sort
6-
The depth of a tree is the ____ of a tree
A -
Number of branches
B -
number of nodes on the tree
C -
number of levels of a tree
D -
All of the above
7-
The characters E, D, C, B, A are inserted into a queu (in the order given, E first
followed by D etc), and then removed one at a time. In what order are they removed?
A -
A B C D E
B -
E A D B C
C -
C B D A E
D -
E D C B A
8-
The root node is to be deleted from the binary search tree given figure.
Which node from the left-hand subtree of node 30 would be used to replace the deleted node?
A -
35
B -
28
C -
20
D -
28
9-
The first step in a very efficient search method to find the pattern "ABCDE" in a vector
of single-character uppercase Strings is to look at Strings with index
A -
5,10,15. …until any letter in"F"…"Z" is encoutered
B -
5,10,15. …until any letter in "A"…"E" is encountered
C -
1,2,3. …until any letter in "A"…"E" is encountered
D -
5,10,15. …until an "E" is encountered
10-
The following items are inserted into a binary search tree: 8, 3, 4, 9, 5, 6, 2, 1, 7. Which
item is placed at a root?