Procedure Function Application - SICP Comparison Edition" /> 1.1.5   The Substitution Model for <span style="color:green"> Procedure </span> <span style="color:blue"> Function </span> Application - SICP Comparison Edition

[1] If the body of the function is a sequence of statements, the body is evaluated with the parameters replaced, and the value of the application is the value of the return expression of the first return statement encountered.
[2] Despite the simplicity of the substitution idea, it turns out to be surprisingly complicated to give a rigorous mathematical definition of the substitution process. The problem arises from the possibility of confusion between the names used for the formal parameters of a procedure parameters of a function and the (possibly identical) names used in the expressions to which the procedure function may be applied. Indeed, there is a long history of erroneous definitions of substitution in the literature of logic and programming semantics. See Stoy 1977 for a careful discussion of substitution.
[3] In chapter 3 we will introduce stream processing, which is a way of handling apparently infinite data structures by incorporating a limited form of normal-order evaluation. In section 4.2 we will modify the Scheme JavaScript interpreter to produce a normal-order variant of Scheme. JavaScript.
1.1.5   The Substitution Model for Procedure Function Application