- Friday, February 6:
- Look at Appendix A and pick out three features of C++ that you
didn't know or would like to learn more about
- Friday, February 13:
- Programming Project 1
- Monday, February 16:
- Homework 1
- Monday, March 8:
- Be prepared to discuss the questions from the HasCl
handout in class.
- Wednesday, March 10:
- Write the following functions in HasCl:
back :: ([a]) -> a -- Return the final element of a list.
For example, back([1, 2, 3]) returns 3 (you may
assume that the function will not be applied to an empty list).
front :: ([a]) -> [a] -- Return a list containing all but
the final element of the argument. For example, front([1, 2, 3])
returns the list [1, 2] (again, you may assume that the argument
will not be empty).
myReverse :: ([a]) -> [a] -- Return the reverse of the
list given as the argument. You may not use the standard library function
reverse, but you may use back and front.
For example, myReverse([1, 2, 3]) returns [3, 2, 1],
while myReverse([ ]) is just [ ].
rotate :: ([a]) -> [a] -- Return the argument list with the
final element rotated to the head. For example, rotate([1, 2, 3])
returns the list [3, 1, 2].
count :: ([a], a) -> Num -- Return the number of times the
second argument occurs in the list given as the first argument. For example,
count([3, 1, 4, 1, 5], 1) returns 2, while
count([3, 1, 4, 1, 5], 2) returns 0.
- Wednesday, March 10:
- Exam 1, 7 pm, Julian Auditorium (JSMC 147)
Practice Exam (PDF)
- Friday, April 9:
- Programming Project 3
- Wednesday, April 28:
- Exam 2, 7 pm, Julian 159
Practice Exam (PDF) and
older [PDF] (with
solutions [PDF])
- Monday, May 3:
- Programming Project 4
- Wednesday, May 19:
- Final Exam, 1-4 pm, Julian 040
Practice Exam (PDF)