CS 3100 Study Guide for Second Exam
COMPUTER SCIENCE 3100 -- Data Structures and Algorithms
Below you will find study questions for the next exam. If you
want more, you can browse the
study guides for the Fall 1998 semester of CS3100.
Chapter Eight -- Class Relationships
-
Be able to explain the relationship between a base class and
a class that has been derived through public inheritance.
-
Understand how to implement "is-a," "has-a," and "as-a"
relationships among classes.
-
Understand what class templates are. Be able to recognize and use
them. Understand the advantage of using class templates.
-
Know what overloaded operators are and their advantages. Know
about how the operator keyword is used when making the
function prototype for an overloaded operator.
Chapter Nine -- Algorithm Efficiency and Sorting
-
Understand the role of operation counts in measuring the work
done by an algorithm.
-
Know the definition of the order of an algorithm -- the big-O
of the algorithm.
-
Understand the importance of big-O analysis as a comparative
measure of growth-rate functions of algorithms. Understand the
way that common big-O rates are ordered: O(1) < O(logN) < O(N)
< O(NlogN) < O(N²) < O(N³) < O(2^N)
-
Know properties of growth rate functions such as O(5*N²) +
O(N) = O(N²)
-
Know the following sorting algorithms and be able to discuss
their orders appropriately: Selection Sort, Bubble Sort,
Insertion Sort, Mergesort, Quicksort, and Radixsort.
-
Be able to discuss the improvements to quicksort discussed in
the text and in lectures.
Chapter Ten -- Trees
-
Know the definitions of all the concepts in the chapter related
to tree anatomy: node, edge, parent, child, sibling, root,
leaf, ancestor, descendant, subtree, height, level, full,
complete, balanced, and so forth.
-
Understand preorder, inorder, and postorder traversal. Know
algorithms for implementing these traversals on a binary tree.
Given a diagram of a tree, be able to list the keys in the
nodes in any of these traversal orders.
-
Know the definition of binary search tree. Understand
the algorithms for doing search, insertion, and deletion in a
binary search tree. Given a diagram of a binary search tree,
be able to draw another diagram showing how the tree would look
if a given element were inserted or deleted by the algorithms
described in our text.
-
Understand how the efficiency of binary search tree operations
depends on the shape of the tree.