![]() | Important |
|---|---|
This page may be updated, and additional study hints may be mentioned during lectures. |
The exams are comprehensive, so any question or topic from quizzes or previous exams may also appear.
The exam is multiple choice, so please bring a ScanTron Form No. 882-E.
Midterms have approximately 20-30 questions.
Note these are suggestions and ideas used in the determining exam questions. It is entirely possible that the exam may incorporate questions that were in the assigned topics list or covered in lectures, but do not appear here.
It is entirely possible that the exam may incorporate questions that were in the assigned topics list or covered in lectures, but do not appear here.
Scheme questions related to the assignment. Question(s) might take the following form(s): Multiple choice questions regarding code fragments or boolean operations and lists. Especially code that deals with list structures, a-lists, cons-cells, testing for null, etc.
Scheme - basic expression evaluation. Misc. questions that explore topics covered during lecture and in the assignments. How will Scheme's read-eval-print-loop respond to various expressions?
Quoted vs. non-quoted evaluation.
List representation; CONS, CAR, CDR, dotted lists, etc.
Tail recursion.
Binding, Scope and Extent questions. Question(s) might take the following form(s): Given a code fragment in Scheme or Java or C++, which value is returned/printed. Unfortunately, these questions may seem like trick questions to those without a solid understanding of binding semantics.
Note, you may postpone your development of Assignment 3, Prolog, until after Midterm #1.
Everyone learns differently -- has their own personal study strategies that work for them. Below are suggestions for how I might study. If you have a better way to study for the exam, by all means...
For the programming languages, mostly Scheme, you should write many, many, many tiny programs. Try to run them. Modify, experiment, and play. If you do not know what tiny programs to write. Try typing in programs shown during lecture. Discuss with your colleagues and friends. Write some more little programs.
For the binding and scoping questions you may want to look at the Java Language Specification (http://java.sun.com) or the Revised 5 Report on Scheme -- R5RS. Also pay attention to the assigned readings.
Although Chapter 5 is assigned reading, you will want to augment this material with Johnny's notes on Bindings, Scope and Extent.
To study binding and typing semantics, you should try to write lots of tiny programs in Scheme, Java, and C++. Experimenting this way can help you to think about what's going on in the language. Each tiny program could explore some binding or scoping issue. Or write tiny programs to experiment with Java or C++ type conversions. Study these small programs with friends or use the class discussion group.
For example, you might try writing a small Scheme program that demonstrates what happens when you try to use indefinite extent-dynamic scoping model. Type in the examples shown in class or in the notes. Verify yourself what is supposed to happen. Do you get a syntax error, semantic-error, or run-time error? Don't get discouraged. Some exam questions may involve how or when a compiler responds to programmer errors. Ultimately, a good familiarity with the programming language environment, tools, and compilers will help you answer exam questions with confidence. Then try some examples in Java, C, and the other languages presented in class or in your text, too.