Intro. to Programming - Spring 2017
MW 12-12:50am - Room 208

Tentative Schedule - as of April 26, 2017

mon     1  jan09 intro: 1st program in class p1
wed     2  jan11 ch 1: programming intro.

mon     H  jan16 Holiday
wed     3  jan18 ch 2: variables Program 2,1040ez

Mon     4  jan23 ch 3: functions (read it)
Wed     5  jan25  Tkinter Man Pages
                  Program 3 assignment
                  p3.py code start

Mon     6  jan30 ch 4: tests and recursion
Wed     7  feb01 Program 4 assignment
                 canvas.py : examples

Mon     8  feb06 ch 5: functions and return values
Wed     9  feb08 

Mon     10 feb13 ch 6: iteration Program 5
Wed     11 feb15 

Mon     H  feb20 Holiday
Wed     12 feb22 ch 7: strings

Mon     13 feb27 ch 8: lists Program 6
Wed     14 mar01 ch 9: tuples

Mon     15 mar06 ch 10: dictionaries Program 7
Wed     16 mar08 

                 Spring Break

Mon     17 mar20 ch 11: files and IO Program 8 - Orbits
Wed     18 mar22 

Mon     19 mar27 Tkinter GUI
Wed     20 mar29  Program 9 - Life
                  a source for sound WAV files:

Mon     21 apr03 Tkinter Canvas
Wed     22 apr05 Program 10 - WWW

Mon     23 apr10 Python classes and objects
Wed     24 apr12 

Mon     25 apr17 Tkinter graphics Program 11 - str find
Wed     26 apr19 

Mon     27 apr24 Tkinter animation  Program 12 - Ray Tracing
Wed     28 apr26 

Mon     29 may01 Tkinter project
Wed     30 may03 

Mon     31 may08 final project review
tue     H  may09 Holiday 
Wed     NC may10 No Classes
Thur    T1 may11 
Fri     T2 may12 8-9:50 Room 228, 10-11:50 Room 228, 12-1:50 Room 208, 4-5:50 Room 258
                 
Mon     T3 may15 
Tue     T4 may16

Instructor: Ted Wetherbee

Fond du Lac Tribal & Community College
2101 14th Street
Cloquet, Minnesota 55720

Office: W217
Phone: 218-879-0840
Email: ted@fdltcc.edu

Fall 2016 Class Schedule:
  8-8:50am   MTWHF  Calculus 1            Room 228
  10-10:50pm M W F  College Algebra       Room 228
  12-12:50pm M W    Intro. to Programming Room 208
  4-5:15pm   M W    Beginning Algebra     Room 258

Office Hours in Room W217:
  Monday   Tuesday  Wednesday  Thursday  Friday
  11-12    9-10     3-4;11-12            9-10

Course Website: math.fdltcc.edu

Click on "wetherbee" then "cs1020" from the web site above. All materials handed out in class will be online from this web site.

Text

How to Think Like a Computer Scientist: Learning with Python, by Allen Downey, Jeff Elkner, and Chris Meyers, edition 2.0.17.

Free PDF (2.0.17)
Online Book (2.0.17)

This book is available in the FDLTCC book store at a reasonable price. Note that there is a Python 3 version available, but we are using the Python 2 version--for little but practical reasons we will explain in class.

Materials needed: USB Key/Drive

Get yourself a USB key/drive. It does not have to be large. Managing your code is a very important aspect of programming!

Create a directory/folder for each programming assignment. Save your Python code often with short but descriptive names in the correct folder. NEVER use spaces in program or directory/folder names! Use underscores_between_words, if necessary. End Python script names with ".py". Disable "hide known file extensions" in a folder view so that you can see the ".py" extensions--which should always be there for Python scripts. When you refine a program, it is extremely helpful to save versions with different names incrementally, e.g. p1.py, p1b.py, p1c.py, and so on.

Include descriptive comments within your Python scripts so that you can later open the file, read comments, and thus know what it does, the author, when it was written, and so forth. You don't have to write a great deal, but you should write enough in a way so that a complete stranger could read your Python script and thus understand what it does, who wrote it, and when it was written. That stranger will usually be yourself! Programmers are humans; it is easy to completely forget almost everything about a code. Explain it to yourself within your code with comments, and do it as if you are writing to a complete stranger.

Computers, PEDs (Personal Electronic Devices)

Do not play games, email, text, chat, surf, talk, etc. etc. on your PEDs. Turn these things off during class and put them away. You will, of course, use computers in class, but don't use your computer during lectures and discussions. Be interactive with humans in the here and now; you will have time to use computers in and outside of class.

SageMath: math.fdltcc.edu/sagemath

This is software like Mathematica and Maple which can do symbolic algebra, graphing, and many other mathematical things. For our purposes, SageMath delivers ipython notebook accounts for interactive Python experimentation.

Note that you have to allow a security exemption for the connection to Sagemath from our FDLTCC server. This is OK for this purpose which is educational. Make up worksheet names which you can remember yet which are not identifiable to yourself.

Room 208 Python

All the room 208 machines have Python 2.7 installed, some also with Python 3. Use Python 2.7 for our class work. As usual for FDLTCC classroom and open lab machines, never expect anything you leave on a machine to remain on the machine! Always copy your programs and other files to a USB key/drive, and label them carefully so that you can find your files later.

Python elsewhere at FDLTCC

All the Mac machines in labs and classrooms have Python installed, and this should be some version of Python 2.6 or 2.7 . Click the Finder (bottom left with the "half-face"), click "Applications" in the left pane, scroll down and click the "Utilities" folder, then click "Terminal". To run Python IDLE: At the terminal prompt (user$), type idle then press Enter.

Installing Python on Your Computer

Python is free. It is probably already be installed if you have a Linux or Mac PC/notebook. There are many free distributions of Python you can install on your Windows machine.

Online Python

You can write and run simple Python programs within this simple Python interpreter right here:

http://cs.fdltcc.edu/skulpt/

This web page loads code within your browser session which converts Python to Javascript, then it runs the Javascript within your browser to simulate results. This is not fully functional Python, but it can be handy for experimentation.

Grading

15 Programs     15 x 50 = 750
15 quizzes      15 x 10 = 150
-------------------------------
                          900 total

90-100%   A
80-90%    B
70-80%    C
60-70%    D
0-60%     F

The Course

You should come to class everyday! This is the easy way to do well in any course, and it is especially true for programming classes. Let me know if there is are accommodations you need for the class.

Note that grades depend on completing programming assignments. Email your completed programming assignment to me (ted@fdltcc.edu) with your program as an attachment. Your program should be self-documented.

The "quizzes" involve programming too, but as smaller snippets of code.

Python is currently the most popular language for learning programming (a recent status.). It is probably the most useful language to know for general use. This happy convergence between ease of learning and practical application has been rare since programming computers developed as a science & art in the late 1950s. Hence, it is easy to find excellent Python programming resources and especially so online.

Because of Python's many uses, we could go in many directions. It is used for systems programming, for games, for scientific applications, for business applications, for online applications, and so on. The essentials of Python are small, but the extensions to Python and its uses are vast.

We will cover basics of Python (which also address principles of programming in any language) and work on selected applications which arise as apt. About half of the course will focus on graphical and online applications; these are remarkably tractable in Python compared to almost any other language.

What might be confusing at first are variations of Python and usage. One can run Python interactively line-by-line in a shell, or execute Python scripts (programs) in an interpreter. There are Cython, iPython, Jython, and others. We will explore iPython (Interactive Python) a bit because this is rapidly becoming popular, and you can see this in action using SageMath.

What you should not overly concern yourself over is the sea of online advice regarding Python. The online Python community is vibrant, large, and mostly tries to be helpful. There is a lot of excellent, valuable material online. Yet, there are some noisy few focused on orthodoxy and eliminating "Python heresy". Use Python as you will in legal and beneficial fashion. You need noone's approval of your style within the limits of course requirements, but do write your own code. You need to write programs which work, not "Pythonic" code to please purists. Do study simple examples that work, and focus on getting results first in straightforward, simple fashion. Please feel free to consult with others in class and myself on your code--but don't ask for online help in programming assignments. (Very, very few people in the online Python community would knowingly help in that.) The easiest way to develop a program in Python is to start with something very simple that works, then incrementally enhance and add features.

Cleary Act Web Link:

http://fdltcc.edu/about-us/policies-reports/campus-security-policies-reports/
Content is neither approved nor reviewed by FDLTCC.