CST1794 Introduction to Programming
Instructional Guide


How to turn in your homework:

D2L: Log into D2L BrightSpace and go to this course, CST1794 Introduction to Programming.  There is an assignment dropbox available for each lab.

The assignment due date is typically one week from when assigned, unless noted otherwise.


Lecture recordings:

Lecture recordings will be published in D2L under course content by the evening of the day they were recorded. If 24hrs go by and you see no recording, notify the instructor.


Downloading Python:

Python can be downloaded from https://www.python.org/

Install the latest Python 3 stable release for your operating system.
For Windows 10 - 11, download the Windows installer (64-bit).
For Mac, download the macOS 64-bit universal installer.


Labs

Lab Student Profile (Described in D2L) (Due Friday morning of the first week!)

Lab D2L & Zoom profile images (Described in D2L) (Due Friday morning of the first week!)

Lab 1 Python Installed (Described in D2L)

Lab 2 Lecture2 (Described in D2L)

Lab 3 Widgets (Described in D2L)

Lab 4 Cube (Described in D2L)

Lab 5 License (Described in D2L)

Lab Astrological Sign

Lab PatternX

Lab Countem

Lab Initial Dots

Lab Count Character Instances

Lab Find Email Phone

Lab Stack

Lab Produce Stand

Lab Scrape Emails

Lab File Trouble

Lab Tkinter GUI


Regular Expressions

Pythex - Python regular expression editor

Regular Expression repository RegExLib

Tutorial on Python regular expressions.


Exceptions

Docs - Built-in Exceptions

Docs - Exception Hierarchy


Python GUI with Tkinter

Videos by Bucky Roberts - thenewboston
YouTube Playlist

Facebook - https://www.facebook.com/TheNewBoston-464114846956315/
GitHub - https://github.com/buckyroberts

Real Python - GUI Programming with Tkinter

Sample icon file (Monsters Inc.)

Gif images you will need to do the in-class exercise:

   


Book Errata

All page numbers refer to text version of 3rd edition.

Double back-quotes indicate code font, e.g. ``ValueError``.

Single *s represent italics, e.g. *raises*.

p.93
Paragraph beginning "The find function ..." mixes up find and index. It should be re-written as follows:
The ``index`` function *raises* a ``ValueError``; this is an example of an exception, which we will talk about in more detail in Chapter 9. The ``find`` function returns -1 if the string being searched for is not found.

p. 141
Replace "html = resp.read()" with "html = page.read()"

p. 156
In the code inside the "print" function, replace "Person('%s', age)" with "Person('%s', %s)".


Book Code

https://code.google.com/archive/p/pythonintro/downloads/


OS X Notes

Apple already has Python installed, however it is an older version, 2.7.10.
Install the newest Python. To access it, put a "3" at the end of commands, i.e. python3.


Lecture Notes

Lecture 1 notes