Graded homeworks. Due to time constraints only four
questions were graded in Homework 7. Homework 8 was not graded; everybody
who turned in a solution got a check for every question.
Solutions for homework 8 will be made available online on the handouts page
on Thursday night. They
will be taken offline on Monday morning. You will need a SUNET id to obtain
Solutions for homeworks 4 through 7 will be handed out in class on
Wednesday 12/3/03. They will also be placed in the handout hangar on
Wednesday. SITN students will receive the solutions via SCPD.
Homework 8 Extension It is now due on Thursday 12/4/03 at 5.00pm.
- Office Hour change Paul's office hours for 11/17 have moved a half
hour earlier than normal to 3:30-5:30.
- Homework 6 Problem 1, part(a)
Activation record (0) should contain r and cp, not x and y.
In the code for this problem, ref(Point) p should be ref(Point) r.
- Homework 6, Problem 2
In the code for this problem, x := a should be x :- a.
- Midterm statistics: Mean: 68, Median: 69, Standard deviation: 11.85
- The midterm exam:
will be closed book. This is largely to save you from spending time looking for answers that are not in the book. There will be some questions that ask for definitions of terms that we have used in class. Other than that, the questions are not recall questions and do include background information you might need.
The midterm will be held at Gates B01 and B03 from 7pm-9pm.
- Name printing policy
In order to give you credit for your submitted homeworks, we need to know your full name unambiguously.
Therefore, we ask you to 1) print your full name legibly in a large, non-cursive font (preferably in capitals)
on your written homework; 2) type in your full name (since we asked for it), e.g. John Smith, when you turn in
your programming assignments electronically.
- Homework 3 problem 7, part (a)-(d)
For homework 3 problem 7, part (a)-(d), you should print (or write)
the answer and attach it to the written part of the assignment. Highlight
what you have filled in for the "missing parts."
Please do not print the whole program, print only the function
that you have changed.
- Homework 3 Problem 2, part (b)
For those who attended Yichen's office hour today, there was some confusion
about what the variables "a" and "c" refer to in c = a^a. It
turns out that by "after", we really meant after the call to power.
To clairfy, the value of a and c in c = a^a are taken after the call. Apologies
for the confusion.
- Homework 3 Problem 7, part (a)
For part a of problem 7, your implementation is for the example code in
the prelude to the problem.
- Homework 3 Problem 7 Submission
For problem 7, put your answer to part (e) in a file named
answer.ml and submit your code.
The file should contain just the implementation
fun function_body() and none of the skeleton code.
- Handout Hanger
There is a filling cabinet on the 4th floor of Gates, on your left as you
you exti the elevators, that contains graded homeworks
and homework solutions. It is marked with a sheet of paper that says
- Homework 2 Programming Extension
Due to an AFS failure on 10/15 the deadline for the electronic submission
of the programming, and only the programming, part of homework 2 has been
extended until 5pm on 10/16.
- Homework 2 Programming Confusion
If you attended Nafis or Paul's office hours today, you may have had some
confusion about how the recursion works in part(b). Specifically, you
might think that there are lots of missing calls to "ev". The code is
correct as written. The statement "case ev(t1)..." is actually where the
recursion happens for the first term, not in the pattern-matching part of
the expression. The same thing is true for "case ev(t2)...". Try tracing
the action of the code on a simple expression like Plus(Const(1),Plus(Const(2),Const(3)))
and this will make more sense. You can refer to
if you're confused about how the case statement works.
- Skeleton code for Homework 2 Updated
Some typos in the skeleton code were corrected.
- Homework 2 Errata
There is a typo on homework 2, problem 6. The last line of
the first paragraph should read:
What integer values are printed by the program using pass-by-name
- Homework Drop Box
There is a homework drop box on the first floor of Gates
near the back close to room 182 and the ATT Patio.
Homework Errata. On question 3, part c, the entire cons cell
(A . B) should be shared by both the top right cell and the top left cell.
- Reduction. We have been getting a lot of questions about
the right way to do reductions. A reduction of a problem B of known
difficulty to a problem A of unknown difficulty shows that problem A is at
least as hard as problem B. To show a reduction, you must show how to
solve B assuming you have a solution of A. Doing so shows that A can't be
easier than B. If A was easier than B then B can't be that hard since you
have just constructed an easy solution to B. Since we know that B is hard, A
must be at least as hard. Thus if you reduce the Halting problem to the A
you have shown that A must be at least as hard as the Halting problem whence
A must be undecidable as well.
Last modified: Mon Nov 17 14:51:22 PST 2003