Introduction
This course is about computation, namely the design of devices that
compute according to some program and also the design of programs
for performing a specic computation. We follow three tracks of study:
1. Well look at mathematical models of
A Haskell Primer Pt. I:
expressions and functions
Overview
To accompany our studies we employ the Haskell programming language. In this rst set of
notes, youll get some working knowledge of programming in Haskell. The goal is to give you
enough syntax to
A Haskell Primer Pt. II:
lists
The study of strings and formal languages is rife with examples of
recursive structures. Its also the case that recursion can be a useful
technique for dening functions on strings. Here we will use Haskell
to explore this ve
Chapter 1
The Basics:
Sets, Tuples & Functions
Sets
A set is a collection of objects. We will usually describe a particular set
by listing its objects, separated by commas, within a pair of opposing
curly braces. For example, the set
cfw_ 2, 4, 6, 8
is t
Chapter 2
The New Basics:
Alphabets, Strings &
Languages
In our introductory M1000 exercise, we considered a very simple computing device that took sequences of button presses as input. In this
section we develop this notion of input sequence more formall
from life import *
from graphics import *
class GraphicLife(Life):
" Class that overrides methods of Life class
in order to work on a graphic display "
def _init_(self, height, width, initial_living):
super()._init_(height, width, initial_living)
self.win