Written by students who passed Immediately available after payment Read online or as PDF Wrong document? Swap it for free 4.6 TrustPilot
logo-home
Document preview thumbnail
Preview 3 out of 24 pages
Exam (elaborations)

CSD Part 1 – study guide and foundational course review material

Document preview thumbnail
Preview 3 out of 24 pages

CSD Part 1 – study guide and foundational course review material

Content preview

CSD Part 1 – study guide and foundational course review material


a - ANS ✔✔Question 1

Marks: 1

After two passes of a sort algorithm, the following array:

47 3 21 32 56 92

has been rearranged as shown below:

3 21 47 32 56 92

Which sorting algorithm is being used?

Choose one answer.

a. all of them.

b. insertion sort.

c. selection sort.

d. bubble sort.



D - ANS ✔✔Which of the following Sorting algorithms use Divide and Conquer strategy?

Choose one answer.

a. Heap sort

b. Radix sort

c. Bubble sort

d. Quick sort



b - ANS ✔✔Question 1

Question 3

Marks: 1

Suppose the frequencies of use of characters is given by:

,A [10%], B [20%], C [70%]

What is the average length of the Huffman codes?

Choose one answer.

a. 2

b. 1.3

c. 1.5

d. 1



b - ANS ✔✔Question 4

Marks: 1

What type of the hash functions that can be used in an English - Vietnamese dictionary?

Choose one answer.

a. Radix transformation

b. Extraction

c. Mid-square function

d. Folding



a - ANS ✔✔Question 5

Marks: 1

A recursive method may be eliminated by using .................

Choose one answer.

a. Iteration statements

b. Stacks

c. All of the others.



b - ANS ✔✔Question 7

, Marks: 1

How many recursive calls to calculate the 5th Fibonacci number?

Choose one answer



a. 22

b. 15

c. 9

d. 32,



d - ANS ✔✔Question 8

Marks: 1

Consider the following algorithm on binary search tree in Java:

--------------------------------------------------------

public static int ABC(BSTNode p){

if (p != null){

return 1 + java.lang.Math.max(ABC(p.left), ABC(p.right));

}

return 0;

}

--------------------------------------------------------

The above algorithm will _______

Choose one answer.

a. None of the others.

b. count number of non-terminal nodes in the tree.

c. count number of nodes in the tree.

d. determine the height of the tree.

Document information

Uploaded on
May 15, 2026
Number of pages
24
Written in
2025/2026
Type
Exam (elaborations)
Contains
Questions & answers
$22.49

Wrong document? Swap it for free Within 14 days of purchase and before downloading, you can choose a different document. You can simply spend the amount again.
Written by students who passed
Immediately available after payment
Read online or as PDF

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
Sanchy062
4.1
(26)
Sold
56
Followers
21
Items
3091
Last sold
1 month ago




Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Working on your references?

Create accurate citations in APA, MLA and Harvard with our free citation generator.

Working on your references?

Frequently asked questions