The course uses an on-line text I have written, found at the
Lectures
page on this site.
We will conduct case studies
in these programming languages:
-
Python:
Python is a scripting language with dynamic data structures;
it supports all of imperative, declarative, and o-o programming.
It is great for developing small- and medium-sized programs quickly.
Systems hackers use it to write utilities and to "glue together"
applications that don't otherwise fit together.
-
* Please read
Installing Python to learn how
to check for Python on your machine, install it if needed, and
use it to develop and test software.
-
* If you have never programmed in Python before, you can relax ---
it looks like Visual Basic or Javascript or any other baby assignment
language. But it has powerful dynamic data structures (lists and
dictionaries) that make it great for language prototyping.
Here are some samples of Python code.
(Here is a zipped folder of the samples.)
Try these with your implementation.
IMPORTANT: Python uses indentation to show the nesting of commands. You can indent using either spaces or tabs, but you cannot mix them. In my examples, I use all spaces to do indentation.
(If you mix leading tabs with leading spaces you will get strange syntax errors.)
-
*
a terse language summary and
terse notes on lists and dictionaries,
the two most important data structures in Python. Here is
a complete tutorial.
-
* The language's website is at
http://www.python.org/,
where you will find a useful
library reference page.
-
* This nice on-line book,
The Python Standard Libary,
shows you how to use Python to do clever systems hacking and gluing,
the sort of stuff that is not normally taught in courses but is hugely useful in
practice.
-
-
ML:
("MetaLanguage") is a functional language that cleverly
combines compile-time type checking with dynamic data structures.
-
* A good reference is the text,
Elements of ML Programming by Jeffrey Ullman (but it's way overpriced --- get a used copy if you wish to buy it).
Here are some other references, all on-line:
* You will probably need to install ML on your computer;
try one of these:
-
SML New Jersey (claims to work
on any of Windows, Mac, Linux)
-
Moscow ML.
(supposedly a ``lighter'' version of ML; works with Windows and Linux)
-
MLton (Linux, Unix, Mac)
-
Prolog: The classic logic-programming language.
-
* There is a good, easy-to-install implementation:
www.swi-prolog.org.
-
* Here is some
intro material on Prolog that I wrote for my CIS301 students.
-
* This material is oriented towards using SWI Prolog:
PLPM, St. Etienne, France |
CSC485, Univ. Toronto
|