Lecture 10 Notes

we create this interface using 1 0 3

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ve definition of factorial. Each call of is made with a promise that the value returned will be multiplied by the value of at the time of the call. Thus is invoked in larger and larger control contexts as the calculation proceeds. §   £  20  D § ¡  §  21 ¡ ¡   ¡    !  C    ¤¢ ©¢  ¢£ "¡ ¥  !    ¤¢ ©¢  ¢£  "¡ ¥       !    ¤¢ ©¢  ¢£  "¡ ¥  !  A    ¤¢ ©¢  ¢£ "¡ ¥  ¡  ¡ !    ¤¢ ©¢  ¢£  "¡ ¥   ¡ !  "¡ ¥  ¤¢ ©¢  ¢£ With these definitions, we calculate: 7    "!¢ ¥©¢  £    § 9¤¡ 8 £ ¥  ¡  ¤"    D § 5!  4    ¢¤¢ ©©  £ ©¨¥ ¤  "¡ ¥  ¡§ £¡ ¡  ¡§   D §    !¢ ©¢  £ "¡ ¥  £ §  § ¨¥  ¨¥ § ¨¥ ¡   fact-iter-acc usage: produces:  ¥©¢  £     4 5!  £ ©¨¥ ¤   ¡§ £...
View Full Document

This document was uploaded on 03/17/2014 for the course CSG 111 at Northeastern.

Ask a homework question - tutors are online