# Week 14

### Monday

• Recipe Card check
• Last class!
• Questions?
• Due: Wed, Dec 6, 11:59pm
• Lecture 16: Lambda
• Lecture 17: Big Oh preview
• Lecture 18: Accumulators (time permitting)
• from slide 41: reversing a list
• Final Exam reminders / review
• Wed, Dec 13, 5-7pm, SP 309 (our regular classroom)
• Review session: Thu? Fri? time?

### Tuesday (A Vassar Thursday: 3:10-5:10pm)

• Last class!
• Pick date for review session: Thu 9–10am
• CEQs
• Lecture 17: Big Oh preview
• Lecture 18: Accumulators (time permitting)
• from slide 41: reversing a list

### Thursday 9am (The real calendar Thursday)

• Review Session and Promises
• Room change for final exam!
• Wed, Dec 13, 5-7pm
• SP 105
##### Review Session Today
• Promises and Study Advice
• Use DrRacket to view course notes, assignments, and labs only. May not use the Stepper or hit the Run button
• Cumulative, but with emphasis on topics we've covered since the last midterm
• Understanding abstraction and higher order functions in general will be important
• Understanding the last two labs, more specifically, will be important
• My solutions to last three labs are posted!
• Budget your time: 100 points / 100 minutes
• Points for each question will be indicated. Between 20-30 points (minutes) for each question
• Exam period is 2 hours (120 minutes), so you should have more time than you need.
• Q1: writing functions for trees. I give you the data definition(s) and a sketch of a tree, you translate the tree into data example(s). Then write a function that consumes a tree based on given data definition.
• Q2: abstracting over two functions, parameterizing, and designing a new higher order function. Then use the new function to rewrite the two original functions. Like we did with +, *, and foldr.
• This is going to be most similar to Lab 9 – the “toast” lab.
• Q3: using higher order functions to gradually simplify your the design of a function. Stages:
• define top-level function
• define a new function that passes the previous top-level function to map, fold, or filter
• revise the last function to use a local expression
• replace the local expression with an anonymous (lambda) function
• Q4: using and evaluating higher order functions: filter, map, foldr, andmap, ormap