Teacher: Mr. A. Milardovic
Starting in September 2019, the grade 11 ICS 3U will be taught using the Python programming language. Students are strongly encouraged to download and install Python on their home computer or laptop.
All course content is delivered through Powerpoint presentations in class and through files in our OneNote classroom which students are given access to at the beginning of the semester. Files in our OneNote classroom can be accessed from home.
Unit 1: Introduction
- What are computers?
- What is programming?
- Can you give instructions?
- Getting started with Python
- Field sizing
- Getting input from the user
- Program development process
Unit 2: Control Constructs
- If structure
- If/else structure
- If/else if/else structure
- Cascading if structures
- Boolean expressions
- Compound Boolean expressions
- Error trapping
- Counted loops
- Nested structures
- Tracing program execution
Unit 3: String Manipulation
- Length command
- Index command
- Other string commands
Unit 4: Functions
Unit 5: File I/O
- Writing data to a file
- Reading data from a file
- Reading and writing at the same time
Unit 6: Arrays
- Creating an array
- Searching and sorting arrays
- arrays and file I/O
This course introduces students to computer science. Students will design software independently and as part of a team, using industry-standard programming tools and applying the software development life-cycle model. They will also write and use subprograms within computer programs. Students will develop creative solutions for various types of problems as their understanding of the computing environment grows. They will also explore environmental and ergonomic issues, emerging research in computer science, and global career trends in computer-related fields.
Required materials: 3-ring binder, paper, pens, pencils
Suggested materials: highlighter, memory stick
- Go to python.org; hover over Downloads and select your operating system.
- Download the latest Python 3 release, which at last check was 3.7.4. Select the “executable installer” version for simplest installation; it will download an executable file which you can run to install Python on your computer.
- Once the download is complete, run the executable to install Python. Standard installation should suit most users.
- The program that we will be using is not Python itself, but the added program IDLE which is installed at the same time. IDLE is the Integrated Development Environment where we will do our coding.
- Once you open IDLE, the first think you’ll probably want to do is go into the Options > Configure IDLE > General tab and change At Startup to Open Edit Window. That way as soon as you start IDLE you can start typing code.
- This page is the starting page for finding information about Python.
- The Python Standard Library describes the syntax and semantics of the Python language, which should be clearer to you as we progress through the course.
- The Python Language Reference is a “to the point” explanation of some of the functionalities of Python.
- The General Index is most detailed and sometimes the best fastest way to find information.
These will be referenced often as we go through the course. Links will be placed on this page for your reference.
- This Python Tutorial is right on the python.org website.
- W3Schools.com has some great tutorials with some interactive options so you can test code while you are learning.
- W3Resource has a large Python tutorial as well.
- Programiz has an extensive Python section on their website.
- The HelloWorld Program site is more lighthearted, but educational nonetheless. There’s even a paper, rock, scissors game already there for you to copy and paste, ready to play!
- RealPython has some great tutorials, some are video tutorials which you can watch parts of before you have to register on the site
If you don’t want to install Python on your home computer you can still use one of several different online IDEs to work on your code. Make sure that whichever one you use that it is using Python 3.7.
- GeeksForGeeks IDE is good for Python as well as many other languages. Select Python 3 and you’re good to go!
- JDoodle is a multi-language online editor; this link takes you directly to Python 3.
- PythonTutor is great because it allows you to visualize what your program is doing in the background while it is running
- Basic Input, Output, and String Formatting in Python
- PyFormat.info for field sizing
- Advanced information about field sizing
- An explanation of the square root function
- Python’s math library
- A huge list of string methods and functions at programiz.com with sample code you can run and edit
- More examples and explanations at W3Schools.com, also with samples you can run
- A good explanation on the Python.org website of strings, especially substrings (slicing)
- This dummies page shows the different methods to search a string in Python, with a good explanation of the parameters for each
- Three ways to reverse a string in Python
- Detailed explanation of functions on the python.org website. You can also find a short explanation of documentation strings (docstrings) here
- Explanation of functions at w3schools.com
- The w3resource.com website also provides a short explanation of how to write a docstring for a function
- Information at Programiz.com
- Tutorial on reading and writing files at RealPython.com
- PythonForBeginners provides a detailed explanation of what happens when you open a file
- StackAbuse shows some snippets of code about handling files, how to read files, how to write files, and how to append to files
- A lot more in-depth than what is needed in this course, DataCamp.com has a very comprehensive explanation of the functionality of File I/O, including how you can use the os module to do other file functions
Check out this page on Finxter which lists over 100 Python books online, most of which are in PDF. Take a look at some of them and let me know if you find a favourite!
If you find any neat resources that you would like to share, please email them to Mr. Milardovic for inclusion on the website.