COMP205 Comparative Programming Languages Part 1: Introduction to programming languages Lecture 2: Structure of programs and programming languages as communication media
Tucker, A. and Noonan, R. Programming Languages: Principles and Paradigms. ... producing a mechanism for writing programs that was more palatable to ourselves. ...
Victoria University of Wellington. Gary Haggard. Bucknell, USA. Gordon Royle. University of Western Australia. COMP205 Software Design and Engineering ...
'Local' definitions can be made using the. where keyword: maxOf3 x ... strings (only for lists of chars): ['h', 'e', 'l', 'l', 'o'] = 'hello' Functions on Lists ...
The type of lists is 'recursively defined': A list is ... is s appended to the concatenation of all the. strings in ss: Patterns. Patterns can be combined: ...
Alan Turing developed an abstract machine (the Turing Machine) and showed that it provided ... the Turing-computable functions were exactly. the general ...
Often it is useful to declare constants in programs: to make the program ... mapList f (IL n l) = IL n (map f l) Main mapList ord (IL 7 'abc') NL 7 [97,98,99] ...
2) auto (automatic) - used to define local variables (including formal ... Parameters can be classified into three groups or modes. They can be used to: ...
A constrained array is an array where the index is specified (and hence the ... A string is a sequence of characters usually enclosed in double quotes. ...
a Horn clause of this form is just written: Predicates ... A Prolog 'program' is a list of Horn-clauses. sometimes such a list is called a 'database' ...
Computing with ?-Terms. How does the ?-calculus relate to real. programming languages such as Miranda? ... In Miranda we can write. twice x = 2 * x. but we ...
interested in the meanings of programs. and their constituent parts ... where Id is the set of variable names. (For simplicity, we assume that all variables ...