EN 811 300 Fundamentals of Computer Programming

 

          To learn problem-solving skills through computer programming.

 

Textbook

* A. Downey, “Think Python.” O’Reilly. 2012.
url: http://greenteapress.com/wp/think-python/

 

Major topics

* Introduction (slide A and slide B)

* Basic input and out

* Basic variable types

* Selection and Boolean

* Iteration

* Collections: list, dict, tuple

* Functions

* Files

 

          Lab and homework assignments

          2017:         Lab01, Lab02 - HW02 (Selection), Lab03 - HW03 (Selection), Lab04 - HW04 (Functions), Lab05HW05 (Functions),

Lab06 (Loops), Lab07HW07 (Loops), Lab08 (List), Lab09 (Dict), Lab10 (Files).

Workshop: Cryptography and Digital Signature, Panpet Srenate.

Class Project.

 

          Computer programming language and tools

                   * Python 3.6

                   * Anaconda

 

Fun examples

* Fun with Turtle module

* GUI with Tkinter (‘tee-kin-ter’)
                   ** text box, message box, and button.

          ** image, draw-over, and mouse event.

* Handy draw-over transparent app
(tricks: transparent, screen capture, checking if file exists. Requires wxPython for GUI, Pillow for screen capture, os for check existing file)

* Fun math: numpy and matplotlib (requires numpy and matplotlib, but both should be available with Anaconda)

* Basic file and Thai encoding: example 1, example 2.

* File update conflict demonstration: program a and program b.

** solution using resource controller

* Easy dbm and pickle: a bucket list (dbm), todo_list (dbm and pickle).

* Simple socket connection

* Caveman’s file transfer

* Basic image manipulation with opencv (requires opencv)

          ** read image, overlay images, write image, and show image.
                   ** capture frame, save video, read video, and show video.
                   ** opencv with tkinter (requires Pillow)

* Fun sound (requires pyglet for instant sound playing; jupyter notebook version)

* Easy multithreading

** Examples of using asyncio from https://pymotw.com/3/asyncio/synchronization.html: Locks, Events, Conditions, Queues.

 

          Jupyter

                   * Fun sound