CSC324 Lecture Notes.doc

13 Pages
Unlock Document

University of Toronto St. George
Computer Science
Gary Baumgartner

CSC324 Lecture NotesSangah is the bestSyntax Vs Semanticsa b c d e f g h SExpressionab c de fg h Terma b c d e f g hPython Lista bc d e f SExpressionSo typicallyspecial semanticsspecial syntaxnot always the case thoughAnything that can be replicated by a function call is eager If something cant then it is not eagerand andare NOT eagerbyvalueParameter names are called formalsSide effects are things that you execute for an effect other than return valueFunction call itself is an operationf1 is like CALL f1 CALL f 1Lambda CalculusLambda Calculus LC is one minimal foundation for Computable FunctionsThree kinds of expressionsFunctionFunction CallParameter AccessOne kind of valuefunctionSemantics Evaluating a program in the core model1 Possible value of an expressionA functionOne of the Booleans true or falsean integerthe void value2 It can also produce sideeffectsPossible Side effectschangealterupdatemutatereassignrebind variablesAbstract Syntax TreeParent Conditional ExpressionChildren LRConditionExpression ConsequentExpression Alternative ExpressionIf condition true then result is consequent else it is alternativeSemantics1 Evaluate conditionexpression In particular any of the expressions sideeffects occur now2 If its result is not false Evaluate consequentexpression In particular any of that expressions sideeffects occur now Its result value is the value of the whole conditionalOtherwise Evaluate alternativeexpression In particular any side effects of it occur now Its result value is the value of the whole conditionalLambda ExpressionLAMBDA FORMALSbodyexpr
More Less

Related notes for CSC324H1

Log In


Don't have an account?

Join OneClass

Access over 10 million pages of study
documents for 1.3 million courses.

Sign up

Join to view


By registering, I agree to the Terms and Privacy Policies
Already have an account?
Just a few more details

So we can recommend you notes for your school.

Reset Password

Please enter below the email address you registered with and we will send you a link to reset your password.

Add your courses

Get notes from the top students in your class.