Homework solutions should be submitted on the course moodle by 11:55 p.m. on the due date. Your write-up should be submitted as a PDF file along with any code (if applicable). Either a typeset or a (legible) handwritten write-up is acceptable.
You are encouraged to work on homework assignments in pairs, enabling pair programming. Homework assignments are the main opportunity to learn material in this course and thus they count for a relatively small portion of your final grade. It is strongly advised that you work on all the problems in a homework assignment together so that you understand all of the material and are prepared for the exam. Everyone will submit assignments, and you must cite your partner explicitly. You may switch partners between assignments, and you are responsible for all assignments individually (e.g., if your partner drops the course midway though an assignment, you still need to submit on time).
Homework Assignment 6
Due Friday, April 20, 2012
- Handout (bug fix in StepAssignLeft, 4/17 11:15am).
- Code Template
- Homework Library (place in the same directory as your homework file)
- Smalla interpreter harness
- Sample Smalla programs: hw6-examples.smalla.
- Smalla example with just assignment and execution log: hw6-assign.smalla, hw6-assign.log (posted 4/12 3:40pm).
- Sample programs for recursive types (bonus): hw6-rectypes.smalla, hw6-linkedlist.smalla
Homework Assignment 5
Due Saturday, April 7, 2012 (with 1 day late period only)
- Handout (updated 3/30 11:33pm, tightened get-field semantics)
- Code Template
- Homework Library (place in the same directory as your homework file, updated 3/29 11:10am with parser)
- Smalla interpreter harness (posted 3/29 11:10am)
- Sample Smalla programs: hw5-match.smalla, hw5-examples.smalla
- Walkthrough of interpreter harness: screencast
Homework Assignment 4
Due Monday, March 12, 2012
- Handout (more hints on question 4, 3/3 2:15pm)
- Code Template
- Homework Library (place in the same directory as your homework file, updated 3/5 9:29pm with bug fix in the parser library)
- Optional: Main for RegExpr match, Main for DynSmalla eval.
Homework Assignment 3
Due Monday, February 27, 2012
- Code Template
- You will also need libHomework2.scala from Homework 2 (no change from Homework 2).
Homework Assignment 2
Due Monday, February 13, 2012
Homework Assignment 1
Due Monday, January 30, 2012
The goal of the teaching project is to identify a topic of your choosing from the course that you will explain to your peers. Most often, this project will involve formulating a concrete example and then walking through the example to illustrate some concept. Such examples may be through diagrams on slides or code.
The main deliverable for this project is a screencast or video that you produce to present your example and explanation. There is no length limit, but we are seeking explanations about 8-15 minutes in length.
You will have the opportunity to do a practice run of your presentation on Thursday, April 26 and Friday, April 27 during class and recitations. These practice runs will not be graded (except for done/not done), but they provide you with an opportunity to get feedback and a check on correctness. While there's no limit on your video productions, you will sign-up for 8 minute slots for your practice presentations. Students presenting on Thursday, April 26 will receive a small amount of extra credit for presenting a day early.
Projects will be done in teams of 4. Each member must speak in the video production/practice presentation. Please also sign-up for a practice presentation where all of your team members can attend.
Take this opportunity as a way to review for the final exam. Pick a topic on which you could use reinforcement.
Evaluation. Take a look at the presentation evaluation form. Your peers will use this form to evaluate your presentation.
Peer Review. You will have to an opportunity to write reviews of your peers' video presentations for extra credit.
Submission. Please submit a high-quality video of your production and a short write-up (~half page) of your intended learning goals. If you have published your video on the web publicly, please give a link to make it easier for everyone to view it.
- Fri, April 20, 2012. On the Homework 6 feedback form, give your team members and a one-sentence summary of your chosen topic.
- Thu-Fri, April 26-27, 2012. Practice presentations. Sign-up for slots are first-come, first-served.
- Wed, May 2, 2012. Videos due.
- Tue, May 8, 2012. Extra credit reviews due.
Sample Project Ideas
These are simply sketches of project ideas. You may come up with your own.
- Explain why a grammar is or is not ambiguous.
- Explain how a grammar might enforce or not enforce associativity/precedence of a binary operator.
- Describe how to represent the abstract syntax of a simple language in Scala and how to implement a recursive traversal.
- Explain the relationship between judgments, judgement forms, inference rules, and derivations.
- Explain how order-of-evaluation can be expressed in a small-step operational semantics.
- Show how to implement and/or use "recursive data structure visitors" like map, foldLeft, etc.
- Explain call-by-value versus call-by-name.
- Discuss aspects of structural induction.
Classes focus on discussion, so it is certainly important to participate in class and read the readings beforehand.
Students are expected to be active participants in the online forums (e.g., around at least 1 substantive post per week). You may and are encouraged to post comments or questions about the reading before the class where we will cover it. Posting early will help focus our discussion.
Here are some examples of good comments:
- Questions about the reading or the class discussion.
- Thoughtful answers to other people's questions.
- Clarification of some point discussed in class.
- Comments on a web resource related to a reading or class discussion (e.g., you happened upon an interesting blog post related to our discussion).
If everything from a class meeting seems clear to you, try to come up with a question that tests your classmates' understanding. Put yourself in the position of an instructor!
Overall, the intent is for you to to take a moment to reflect upon the day's reading or class discussion. I will read all posts, but I may not respond to all of them (e.g., if I believe your classmates' answers are sufficient).