22C:16 Computer Science I: Fundamentals.
Final Exam Information
The Final Exam will be held on Wednesday, May 11th from noon to 2:00 pm.
This is an open notes exam,
worth 20% of your grade and it will be marked out of 200 points.
Important Note: The exam will be in 100 PH (Philips Hall). This is not our
usual classroom; neither is it the other large auditorium we used for past exams. All students should come to this classroom.
There will be three problems on the test and details of these problems are
given below.
- Problem 1. [70 points] On dictionaries.
There will be two parts to this problem.
- In this problem, you will be given some expressions that involve
dictionaries (as well as strings, lists, and tuples). Your task will be to
evaluate these expressions.
- In this problem, you will be given a problem and asked to write code
that involves dictionaries. For example, take a look at Quiz 10.
- Problems 2. [70 points] On recursion.
There will be two parts to this problem.
- In this problem, you will be asked to ``trace'' (i.e., execute by hand)
a given recursive function.
The given function will contain code you are already familiar with for the most
part, e.g., functions fibonacci, power, binarySearch, mergeSort, etc.
You will not have to write code for this problem.
To get ready for this problem make sure you review these functions and
you understand how they work.
This will be similar to what you did for Quiz 12.
- In this problem, you will be given a problem and asked to write a
recursive function to solve it.
This problem will not require much code, 5-6 lines at most (for e.g., see Problem 4 on HW9 and also look over Quiz 11).
- Problems 3. [60 points] On classes and objects.
This problem will have two parts.
- In this part, you will be given a class implementation and will be asked
questions about how to use it. For example, you could be
given the twoDice class and asked to evaluate expressions that call
the constructor or other methods in the twoDice class.
- In this part, you will be given specifications of a class and asked to
implement it. See for example, Quiz 13.
I may throw in requirements that your class implementation be able to handle errors correctly. This will involve recent things you have learned such as
try, except, and raise.