正在加载图片...
6.001 Structure and Interpretation of Computer Programs. Copyright o 2004 by Massachusetts Institute of Technology Slide 12.3.17 name rule, is just the double bubble pointed to by that variableo mple cont d: (inc-square 4)I Ge As in the previous case, this is a compound expression need to first evaluate the subexpressions with respect to same environment. The value of inc-square, by tnc-square b:*xx)B:+1 (square y)) Example contd: (inc-square 4)I gE Slide 12.3.18 And as we saw before, our four-step rule kicks in. Step one: csquare: create a fram P: Y b:(*xx)b:(+1 inc-square I Er=>#Icompound-proe..I 6001 SIC specified by the procedure that is being appll vironment g/Example cont d: (ing-square 4)I Slide 12.3.19 Step two: turn it into an environment, by having the encloser environment pointer of the frame point to the env 1 inc-squareg Example contd: (inc-square 4)I gE Slide 12.3.20 and that we know is specified by the second part of the double bubble of the procedure being used (square y)) ind-square I cr >#Icompound-proc ..I6.001 Structure and Interpretation of Computer Programs. Copyright © 2004 by Massachusetts Institute of Technology. Slide 12.3.17 As in the previous case, this is a compound expression, so we need to first evaluate the subexpressions with respect to the same environment. The value of inc-square, by the name rule, is just the double bubble pointed to by that variable. Slide 12.3.18 And as we saw before, our four-step rule kicks in. Step one: create a frame. Slide 12.3.19 Step two: turn it into an environment, by having the enclosing environment pointer of the frame point to the environment specified by the procedure that is being applied... Slide 12.3.20 ... and that we know is specified by the second part of the double bubble of the procedure being used
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有