|
CISC 260: Programming Paradigms
Resources
Winter 2007
|
The textbook for this course is "Programming Paradigms", available at the Queen's book store. This is a custom text, not available elsewhere. It consists of selections from a Haskell text and a Prolog text. That saves you from having to buy two textbooks. A few students from previous years told me they would rather have had both textbooks in entirety. If you're interested in buying the original texts, they are:
- Haskell: The Craft of Functional Programming, second edition, by Simon Thompson, ISBN 0-201-34275-8
- Prolog: Programming for Artificial Intelligence, third edition, by Ivan Bratko,
ISBN 0201-40375-7
Both books are available from amazon.ca and chapters.indigo.ca. There are other Haskell and Prolog texts on the market, but they don't all cover the same topics in the same order, so they might not fit as well with this course.
The tool to use for running Haskell is Hugs 98. I will be demonstrating the use of Hugs during lectures.
Hugs is available on both the CASLab machines (both Windows and Linux). For your home computer, you can download Hugs from
http://haskell.cs.yale.edu/hugs. It's free and available in versions
for Windows, Linux and Macintoshes.
There are other Haskell interpreters and compilers available, but please don't use them for CISC 260. The Haskell language and libraries are not completely standardized and if we all use the same tool we will avoid huge amounts of confusion. Marking of assignments, quizzes and exams will assume you're writing Haskell for use in Hugs.
- The Hugs home page contains links to documentation about the Hugs tool.
- The Haskell home page contains a huge list of Haskell-related links.
- A Gentle Introduction To Haskell is a nice tutorial.
Please consider this a supplement to the required text, not a possible replacement. It covers Haskell
in a very different way and in a different order.
- The web site for Haskell: The Craft of Functional Programming (the Haskell portion of the custom textbook) contains some interesting Haskell-related information, an errata page, and all of the Haskell code from the book for downloading.
The tool to use for running Prolog is SWI-Prolog. I will be demonstrating the use of SWI-Prolog during lectures.
It is available on both the CASLab machines (both Windows and Linux). For your home computer, you can download
SWI-Prolog from
http://www.swi-prolog.org/. It's free and available in versions
for Windows, Linux and Macintoshes.
There are other Prolog interpreters and compilers available, but please don't use them for CISC 260. Prolog versions
and tools vary even more than Haskell. As with Haskell, marking of assignments, quizzes and exams will assume you're writing Prolog for use with SWI-Prolog.
- The SWI-Prolog Reference Manual. If you
click on the icon that looks like a card file, it takes you to the table of contents. Chapter 2 is an
overview, including a "Getting Started Quickly" section. (The "likes.pl" file referred to there is in
the "demo" folder inside your installation folder.) Appendix A describes all the built-in predicates.
Section A.1 is particularly useful, since the built-in list manipulation predicates are a bit different
from those described in the text. Section 4.1 explains the notation used in this appendix and elsewhere in
the manual.
- The SWI-PROLOG home page contains documentation for the tool as well as other Prolog-related links
- The
companion website for the Bratko textbook (the second half of the custom text) contains most of the
examples from the textbook ready for download
- Prolog Programming: a do-it-yourself course for beginners from Saarland University in Germany.
- Prolog Tutorial another tutorial, this one from California State Polytechnic University.
If you'd like to subscribe to a podcast of all the lecture audio, paste the
following URL into your podcatcher:
http://www.cs.queensu.ca/home/cisc260/2007w/podcast/podcast260.xml.
If you'd rather download them one at a time, there are links in the schedule page.
Now that the winter 2007 term is over, the audio files
have been deleted to save space on the server. If any former students
have a need for them, please contact me.
I've had some questions about the text editor I use in class. It's notepad++ and
it's a free download from http://notepad-plus.sourceforge.net/uk/site.htm.
There isn't extensive documentation, but the editor is pretty easy to figure out. To
define a new language mode or modify one you've already got, go to View -> User Define Dialog.
If you'd like a copy of the simple Haskell and Prolog languages I've created, search your
computer for a file called userDefineLang.xml; on my computer it's located in
c:\Documents and Settings\Margaret\Application Data\Notepad++. Make a copy of this
file now so that if anything goes wrong, or you don't like my language modes, you can
put things back the way they were. Now download a copy of
my version of userDefineLang.xml into the same
folder to replace the old version. Next time you open up notepad++, look at the
language menu and you should see haskell and prolog at the very bottom; you may have to scroll down.
When you open a file with extension .hs, it will automatically open in haskell mode.
Unfortunately, the extension .pl is reserved for Perl and I haven't figured out how to
hack Notepad++ to get rid of that association. But you can use the language menu to
enter prolog mode.
Warning: the process above will destroy any languages you may already have defined.
If you want to merge my languages in with yours, you'll have to cut and paste from
my xml file into your own.
back to home page
This page maintained by
Margaret Lamb,
Queen's University, Kingston, Ontario. Last modified