COMPSCI 61A Study Guide - Final Guide: Cheat Sheet, Eval, Init
![COMPSCI 61A Full Course Notes](https://new-docs-thumbs.oneclass.com/doc_thumbnails/list_view/2415239-class-notes-us-berkeley-compsci-61a-lecture15.jpg)
22
COMPSCI 61A Full Course Notes
Verified Note
22 documents
Document Summary
If you are not sure of your answer you may wish to provide a brief explanation. All the work on this exam is my own. (please sign: 1 q. For each row below, write the output displayed by the interactive python interpreter when the expression is evaluated. Expressions are evaluated in order, and expressions may a ect later expressions. Whenever the interpreter would report an error, write error. You should include any lines displayed before an error. Reminder : the interactive interpreter displays the repr string of the value of a successfully evaluated expression, unless it is none. The pair class from project 4 is described on your nal study guide. Recall that its __str__ method returns a scheme expression, and its __repr__ method returns a python expression. The full implementation of pair and nil appear at the end of the exam as an appendix. Pair(nil, pair(4, nil)) (9 (6 : 9 8 .