• Wrong document? Swap it for free
  • Written by students who passed
  • Immediately available after payment
  • Read online or as PDF
Sell
Where do you study
Your language
Document preview thumbnail
Preview 2 out of 6 pages
Exam (elaborations)

Exam 2 CSE 310 with correct answers

Document preview thumbnail
Preview 2 out of 6 pages

Exam 2 CSE 310 with correct answers

Content preview

Exam 2 CSE 310 with correct answers
|\ |\ |\ |\ |\ |\




Binary Search Tree properties - CORRECT ANSWERS ✔✔Each
|\ |\ |\ |\ |\ |\ |\ |\


node has 0 to 2 children
|\ |\ |\ |\ |\




Children on left are less than parent
|\ |\ |\ |\ |\ |\




Children on right are greater than parent
|\ |\ |\ |\ |\ |\




Dynamic Set Operations - CORRECT ANSWERS ✔✔Add, Delete,
|\ |\ |\ |\ |\ |\ |\ |\


Minimum, Maximum, Search, Predecessor, Successor
|\ |\ |\ |\




Binary Search Tree minimum - CORRECT ANSWERS ✔✔Returns
|\ |\ |\ |\ |\ |\ |\ |\


the bottom left most node
|\ |\ |\ |\




Binary Search Tree Maximum - CORRECT ANSWERS ✔✔Returns
|\ |\ |\ |\ |\ |\ |\ |\


the bottom right most node
|\ |\ |\ |\




In order traversal - CORRECT ANSWERS ✔✔left, root, right
|\ |\ |\ |\ |\ |\ |\ |\




Pre order traversal - CORRECT ANSWERS ✔✔root, left, right
|\ |\ |\ |\ |\ |\ |\ |\




Post order traversal - CORRECT ANSWERS ✔✔left, right, root
|\ |\ |\ |\ |\ |\ |\ |\




Tree predecessor - CORRECT ANSWERS ✔✔returns the greatest
|\ |\ |\ |\ |\ |\ |\ |\


number less than x |\ |\ |\

, Tree successor - CORRECT ANSWERS ✔✔returns the lowest
|\ |\ |\ |\ |\ |\ |\ |\


number greater than x |\ |\ |\




Which traversal helps with predecessor/successor - CORRECT
|\ |\ |\ |\ |\ |\ |\


ANSWERS ✔✔In Order traversal |\ |\ |\




Binary search tree search runtime - CORRECT ANSWERS ✔✔O(h)
|\ |\ |\ |\ |\ |\ |\ |\




Binary search tree insert runtime - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\


✔✔O(logn)


Binary search tree transplant runtime - CORRECT ANSWERS
|\ |\ |\ |\ |\ |\ |\ |\


✔✔O(1)


Properties of RB BST - CORRECT ANSWERS ✔✔Every node is
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\


either red or black
|\ |\ |\




Every null node is black
|\ |\ |\ |\




Every red node has black children
|\ |\ |\ |\ |\




Every path has the same number of black nodes
|\ |\ |\ |\ |\ |\ |\ |\




The root is black
|\ |\ |\




T/F: RB Trees can have a path that is twice as long as another -
|\ |\ |\ |\ |\ |\ |\ |\ |\ |\ |\ |\ |\ |\ |\


CORRECT ANSWERS ✔✔False |\ |\




Red Black Tree insert run time - CORRECT ANSWERS ✔✔O(logn)
|\ |\ |\ |\ |\ |\ |\ |\ |\

Document information

Uploaded on
July 4, 2025
Number of pages
6
Written in
2024/2025
Type
Exam (elaborations)
Contains
Questions & answers
$15.99

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.
EXAMSTUDYPLUG
4.5
(242)
Sold
392
Followers
107
Items
20959
Last sold
1 week 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