Introduction to Computer Programming in Python
University of Texas at Austin
Texas Summer Discovery Program 2021

Instructor: Dr. Bill Young (

Class time: M-Th 6-8am CDT; Location: online

Instructor Office: GDC 7.810;
Instructor Office Hours: by appointment

This website:

Important Class Announcements:

Breaking news important to the class will be posted here. Consult this spot often.

I will usually post any assigned work here, but don't forget it's also down the page.

Feel free to email me (Send me an email message).

Course Description:

Python is a very popular high-level computer programming language. Developed in the late 1980s, it was released in 1991, and has become one of the most widely-used programming languages worldwide. It is now taught by 80% of the top university computer science departments.

Students will be introduced to basic computer hardware, organization, and architecture to understand what software programs are and how they work. Python topics will include basic data types, simple I/O, decision structures, loops and functions. By the end of the course, students will be able to write complete Python programs to perform mathematical and logical tasks.

The tentative class schedule is here: Schedule. We'll probably stick pretty close to this, but some of the topics may differ slightly.

Student Responsibilities:

Your performance in this class will be determined by you. It will require dedication to learning the material, and may require a substantial time commitment to complete the programming assignments.

We are going to try to cover quite a lot of material. It's very important that you keep up and do the assignments on time.

You are expected to:

You are free to discuss the course materials with your classmates and you are encouraged to form study groups for the exams. Collaboration on homework or exams is not permitted. Helping a classmate to understand the intent of an assignment specification is permitted.

During classtime, please silence your cell phone and put it away. Since this class is online, you are expected to use laptops or similar devices in class, but it should only be for note-taking, performing exercises, and other class-related tasks. Please avoid engaging in any non-class-related behavior (checking email, surfing the Internet, chatting with friends, etc.)

You may come and go as you wish (to use the restroom, for example) during class without asking permission. However, please do so without disturbing others and be aware that you are still responsible for any class material you may miss during your absence.

This will be a small, interactive class. You are encouraged to make comments, ask questions, and participate actively. I hope to make attending class a pleasant and interesting experience for you so that fulfilling your student responsibilities will be easy.

Course Topics

Week 1:

Week 2:

Week 3: (as time permits)

Course Slides:

Slideset 1: What Is a Computer? 4up-PDF  PDF

Slideset 2: Introduction to Python 4up-PDF  PDF

Slideset 3: Variables and Assignments 4up-PDF  PDF

Slideset 4: Arithmetic 4up-PDF  PDF

Slideset 5: Data Types and Input Function 4up-PDF  PDF

Slideset 6: Built-in Functions and Libraries 4up-PDF  PDF

Slideset 7: Booleans and Conditionals 4up-PDF  PDF

Slideset 8: Loops 4up-PDF  PDF

Slideset 9: Functions 4up-PDF  PDF

Slideset 10: Strings 4up-PDF  PDF

Slideset 11: Lists 4up-PDF  PDF

Slideset 12: Recursion 4up-PDF  PDF

Slideset 13: Randomness 4up-PDF  PDF

Slideset 14: File I/O 4up-PDF  PDF

Slideset 15: Turtle Graphics 4up-PDF  PDF

Grading Procedures:

Your performance in this class will be evaluated using your scores for eight programming assignments and three exams.

Homeworks (40%):

There will be 8 programming assignments. You will have to download and install software (Python and a graphical development environment called IDLE) to your laptop. The software is free from

The only way to learn programming is by writing programs. Doing the programming assignments is crucial to doing well in this class. Assignments will be given almost every class period and will be due at the start of the next class period. Assignments start out easy, but get harder over time. If you find that you have considerable difficulty with the first few assignments, please see the Instructor immediately.

Each assignment is due at the start of the next class period. Turn in your assignments on time. If you miss the deadline, you can also turn in your assignment up to 24 hours late for a 10% penalty. After that, your assignment won't be graded and you will receive a zero for that assignment.

Specific grading criteria change with each assignment. In general, programs that don't even run won't receive more than 80% of the possible points. Other point deductions are given for such things as incorrect results, missing features, bad logic, no documentation, etc.

All assignments will be submitted by uploading your source code to an Assignment in Canvas. The source code must be in a text file that can be run through the Python interpreter. Word processing files (such as those created with Microsoft Word, for example, and ending with the .doc extension) will not be accepted. Remember to keep a copy of yoru source code (i.e., the .py file) somewhere, unedited after you submit it. This will help in case your program gets lost or corrupted, and the timestamp on the file can be used to prove that you completed the assignment on time.

Exams (60%):

There will be three exams, each worth 20% of your total grade. Each exam will take place on Thursday.

Make up exams will be given only for ill health or a family emergency. In all cases you should provide proof.

Final Grades:

A standard plus/minus system will be used to calculate the final grade tentatively using the following grade ranges. I reserve the right to be more generous than this; I will not be less generous.

Course score Grade
[90... 94)A-
[87... 90)B+
[84... 87)B
[80... 84)B-
[77... 80)C+
[74... 77)C
[70... 74)C-
[67... 70)D+
[64... 67)D
[60... 64)D-
[ 0... 60)F

Academic Integrity:

You are expected to follow this honor code:

University of Texas Honor Code: the core values of The University of Texas at Austin are learning, discovery, freedom, leadership, individual opportunity, and responsibility. Each member of the university is expected to uphold these values through integrity, honesty, trust, fairness, and respect toward peers and community. Each student in this course is expected to abide by this code. Any work submitted by a student in this course for academic credit will be the student's own work.

Some Interesting Links:

Some interesting material about careers in computing can be found here: Careers in Computing

A student found these online texts to be useful resources: Automate the Boring Stuff with Python, Think Python 2e

Good turtle graphics documentation: Turtle Graphics
Turtle tutorial: Tutorial.
Some nice turtle projects: Projects.
Some issues around floating point: FP issues
Some nice videos on Python from the Khan Academy: Khan Academy Videos.

Sooyong created two videos that shows how to create a file in an editor and run it in Windows and MacOS. If you still aren't able to do that, I suggest you watch either: Windows video or MacOS video.

Python Links

Python Tutorials and Books

Miscellaneous Information on Python