Grade by Grade
Ontario · Grade 11 · ICS3U

Introduction to Computer Science

A. Programming Concepts and Skills

Programming Basics: Data, Decisions and Loops

This unit is your start in computer science. You will write real programs in Python 3, beginning with a single print statement and finishing with programs that read input, make decisions, repeat steps and check their own data.

You will learn to use variables and constants with the four basic data types (integers, floats, strings and Booleans), and you will see what is really inside the computer: how numbers are stored in binary and hexadecimal, and how text is stored with ASCII and Unicode. You will write arithmetic, string, comparison and Boolean expressions in the correct order of operations, plan programs with the input, process, output model, and use the three control structures: sequence, selection (if, elif, else) and repetition (while and for loops), including nested structures that count, total and find the highest and lowest values. All the way through, and especially in the last two lessons, you will practise professional code maintenance: reading error messages, fixing syntax, run-time and logic errors, tracing code, testing it with a full range of test cases, and writing clean, well-named, well-commented code.

No programming experience is needed. If you took Grade 9 math (MTH1W), you have already read and changed some short Python programs; this unit starts again from the beginning and goes much deeper. All you need is a computer, Chromebook or tablet with Python 3 (free from python.org, the Thonny editor, or a free online Python 3 editor). Every lesson has worked examples, programs whose output is shown, a hands-on activity, lots of practice with answers, and a short quiz. Type the code yourself rather than copying it: it is the best way to learn, and copied indentation from a web page can contain invisible characters that Python rejects.

The next unit, Arrays and Subprograms, builds on this one with lists (one-dimensional arrays), string tools, functions, and searching and sorting.

Curriculum: The Ontario Curriculum, Grades 10 to 12: Computer Studies (2008), Introduction to Computer Science, Grade 11, University Preparation (ICS3U), strand A. Programming Concepts and Skills: A1.1 to A1.4 (data types and expressions), A2.1 to A2.3 (control structures and simple algorithms) and A4.1 to A4.5 (code maintenance). Expectations A1.5, A1.6 and A3 (arrays and subprograms) are taught in the unit Arrays and Subprograms, which also continues A4.

1Your First Python Programs: Output, Sequence and Comments
65 min
A2.1 A2.2 A4.2
2Variables, Constants and Assignment Statements
70 min
A1.1 A1.3 A4.2 A4.4
3Data Types: Integers, Floats, Strings and Booleans
65 min
A1.1 A1.3 A4.1
4Arithmetic Expressions and the Order of Operations
70 min
A1.3 A1.4
5How Computers Store Numbers: Binary and Hexadecimal
70 min
A1.2
6How Computers Store Text: ASCII and Unicode
65 min
A1.2
7Input, Processing and Output with String Expressions
70 min
A2.1 A1.3 A1.1
8Boolean Expressions: Comparison and Logical Operators
65 min
A1.4 A1.1
9Selection: if, elif and else
70 min
A2.2 A4.2
10Nested and Compound Selection
70 min
A2.2 A2.3 A1.4 A4.4
11Repetition with while Loops
70 min
A2.2 A2.1 A4.4
12Counted Repetition: for Loops and range
70 min
A2.2 A1.3 A4.2
13Nested Structures: Counting, Totals, Highest and Lowest
75 min
A2.3 A2.2 A2.1
14Finding and Fixing Errors: Syntax, Run-Time and Logic
70 min
A4.1 A4.3 A4.2
15Tracing, Testing and Writing Clean Code
75 min
A4.4 A4.5 A4.2 A4.1
16Programming Basics: Data, Decisions and Loops: Unit Review
40 min
A1.1 A1.2 A1.3 A1.4 A2.1 A2.2 A2.3 A4.1 A4.2 A4.3 A4.4 A4.5
A. Programming Concepts and Skills

Arrays and Subprograms

In Programming Basics you learned to store one value in a variable and to control a program with selection and loops. In this unit you learn to handle many values at once and to organize code into reusable parts.

The first half is about one-dimensional arrays, which in Python are lists: their structure (elements, indexes and bounds), how to declare, initialize, access and modify them, and the classic algorithms that work on them: counting, totals and averages, highest and lowest values, linear search, sorting (selection sort and bubble sort), and inserting into or deleting from a list. You will also treat strings as sequences and take substrings.

The second half is about subprograms. You will use existing ones (built-in functions, the math and random modules, string methods), then write your own functions and procedures with parameters and return values, learn exactly how parameter passing works for numbers and lists, and use local and global scope correctly. You will design programs modularly with structure charts and a main() function.

Throughout, you practise professional code maintenance: reading error messages, tracing, fixing syntax, run-time and logic errors, documenting code with docstrings, and validating programs with a full range of test cases. The unit ends with a complete menu-driven project.

All code is Python 3. You only need a computer with Python installed (IDLE or Thonny are free) or a free browser-based Python.

17Lists as One-Dimensional Arrays: Elements, Indexes and Bounds
70 min
A1.5 A1.6 A4.3
18Declaring, Initializing, Accessing and Modifying Lists
70 min
A1.6 A1.5 A4.1
19Traversing a List: Counting, Totals and Averages
70 min
A2.3 A1.6 A4.4
20Highest, Lowest and Linear Search
70 min
A2.3 A1.6 A4.5
21Strings as Sequences: Characters, Substrings and String Methods
70 min
A3.1 A1.5 A2.3
22Using Built-in Functions and Modules
65 min
A3.1 A4.3
23Writing Your Own Functions
70 min
A3.2 A4.2 A4.3
24Parameter Passing: Arguments, Defaults and Lists
70 min
A3.2 A1.6 A4.4
25Variable Scope: Local and Global
65 min
A3.2 A4.2 A4.1
26Modular Design: Building Programs from Subprograms
70 min
A3.2 A3.1 A4.2
27Sorting Algorithms: Selection Sort and Bubble Sort
75 min
A2.3 A1.6 A3.2 A4.4
28Inserting, Deleting and Parallel Lists
70 min
A1.6 A2.3 A3.2 A4.4
29Testing and Debugging Programs with Lists and Functions
75 min
A4.1 A4.3 A4.4 A4.5
30Putting It Together: A Modular List-Processing Program
75 min
A1.6 A2.3 A3.1 A3.2 A4.2 A4.5
31Arrays and Subprograms: Unit Review
40 min
A1.5 A1.6 A2.3 A3.1 A3.2 A4.1 A4.2 A4.3 A4.4 A4.5
B. Software Development

Software Development: Problem Solving, Design, Testing and the Life Cycle

Writing code is only one part of making software. In this unit you will learn how programmers plan, design, build, test and deliver programs that people can rely on.

You will start with problem-solving strategies (stepwise refinement, divide and conquer, working backwards, examples and extreme cases, tables and trial and error), the input-process-output model, and how to work independently and in teams. Then you will design programs with industry-standard tools: flow charts, pseudocode, structure charts, data flow diagrams and UML, using modular, reusable code, program skeletons and user-friendly interfaces. You will design algorithms to specifications: formulas (hypotenuse, primes, area and circumference), inserting into and deleting from sorted arrays, and exception handling (division by zero, roots of negatives, bad input). Finally you will follow the software development life cycle: clarifying specifications, planning with Gantt, critical path and PERT charts, testing with test plans, debugging by tracing and printing variable state, and writing status reports, ending with a mini project that uses everything.

Remember from the other units of this course: Programming Basics taught variables, input and output, selection and loops; Arrays and Subprograms taught lists and functions. This unit assumes both. Every code sample uses Python 3 and runs exactly as shown; all you need is a computer with Python (IDLE or Thonny) or a free browser-based Python. Every lesson has worked examples, a hands-on activity, lots of practice and a short quiz. These skills lead directly to ICS4U (Grade 12 Computer Science).

Curriculum: The Ontario Curriculum, Grades 10 to 12: Computer Studies (2008, revised), Introduction to Computer Science, Grade 11, University Preparation (ICS3U), strand B. Software Development: B1.1 to B1.3 (problem-solving strategies), B2.1 to B2.5 (designing software solutions), B3.1 to B3.3 (designing algorithms to specifications) and B4.1 to B4.6 (the software development life cycle).

32Problem-Solving Strategies for Programmers
70 min
B1.1
33The Input-Process-Output Model
65 min
B1.3
34Solving Problems Alone and in Teams, and Talking About Designs
65 min
B1.2 B2.2
35Designing with Flow Charts and Pseudocode
70 min
B2.4 B2.2
36Structure Charts, Data Flow Diagrams and UML
70 min
B2.4 B2.2 B2.3
37Modular Design: Reusable Code and Program Skeletons
70 min
B2.3 B2.1
38Designing User-Friendly Interfaces
65 min
B2.5
39Formulas in Algorithms: Hypotenuse, Primes, Area and Circumference
70 min
B3.2
40Algorithms to Specification: Inserting and Deleting in a Sorted Array
70 min
B3.1
41Detecting and Handling Exceptions
70 min
B3.3
42The Software Development Life Cycle and Clarifying Specifications
70 min
B4.1 B4.2
43Planning a Project: Gantt Charts, Critical Paths, PERT and Status Reports
75 min
B4.3 B4.6
44Testing with a Test Plan: Expected versus Actual
70 min
B4.4
45Debugging Methods: Tracing and Printing Variable State
70 min
B4.5
46Mini Project: Building a Program Through the Whole Life Cycle
75 min
B4.1 B4.2 B4.4 B4.6 B1.2 B1.3 B2.1 B2.5
47Software Development: Problem Solving, Design, Testing and the Life Cycle: Unit Review
40 min
B1.1 B1.2 B1.3 B2.1 B2.2 B2.3 B2.4 B2.5 B3.1 B3.2 B3.3 B4.1 B4.2 B4.3 B4.4 B4.5 B4.6
C. Computer Environments and Systems

Computer Environments and Systems

In this unit you will learn how the computer you program actually works, how to keep your work organized and safe, and what the tools you code with really do. You will start inside the computer: the CPU, RAM, ROM, cache, storage, motherboard, power supply, video and sound hardware, and how to read their specifications (GHz, GB, TB, MT/s, Mbps) with real arithmetic. You will compare peripherals such as monitors, printers and scanners, use a weighted decision matrix to recommend a computer for a real user, and follow a program as the CPU fetches, decodes and executes it, using a pretend CPU written in Python.

Next you will organize files on local, shared and cloud drives, learn how viruses, worms, Trojan horses, spyware, adware, ransomware and malicious macros work, write a system protection plan, and back up and archive your files using the 3-2-1 rule. Finally you will explore the IDE and its debugger, learn to work independently with documentation, and explain the differences between source code and machine code, interpreters and compilers, and operating systems, applications and programming languages.

You need a computer with Python 3 (or a free browser-based Python) and an IDE such as IDLE or Thonny. Every code sample has been run and shows its exact output. This unit works alongside the other ICS3U units, Programming Basics, Arrays and Subprograms, Software Development and Topics in Computer Science, and connects to the Grade 12 course ICS4U (Computer Science).

Curriculum: The Ontario Curriculum, Grades 10 to 12: Computer Studies (2008, revised), Introduction to Computer Science, Grade 11, University Preparation (ICS3U), strand C. Computer Environments and Systems: C1 (relate the specifications of computer components to user requirements: C1.1 to C1.4), C2 (use appropriate file maintenance practices to organize and safeguard data: C2.1 to C2.3) and C3 (demonstrate an understanding of the software development process: C3.1 to C3.5).

48Inside the Computer: Internal Components and Their Specifications
70 min
C1.1
49Reading Computer Specifications: Processors, Buses, Memory and Storage
70 min
C1.2
50Peripheral Devices: Monitors, Printers, Scanners and More
65 min
C1.3
51Choosing a Computer: Matching Specifications to User Requirements
70 min
C1.1 C1.2 C1.3
52How a Program Runs on the Hardware
70 min
C1.4
53Organizing Programs and Files on Local and Shared Drives
65 min
C2.1
54Malware: Viruses, Worms, Trojans, Spyware and More
65 min
C2.2
55Building a System Protection Plan
70 min
C2.2
56Backing Up and Archiving Files
70 min
C2.3
57The Integrated Development Environment: Editor, Translator and Debugger
70 min
C3.1 C3.2
58Working Independently with Documentation and Help
65 min
C3.2
59Source Code and Machine Code
65 min
C3.3
60Interpreters and Compilers
65 min
C3.4 C3.3
61Applications, Programming Languages and Operating Systems
65 min
C3.5
62Computer Environments and Systems: Unit Review
40 min
C1.1 C1.2 C1.3 C1.4 C2.1 C2.2 C2.3 C3.1 C3.2 C3.3 C3.4 C3.5
D. Topics in Computer Science

Topics in Computer Science: Sustainability, Emerging Research and Careers

This unit looks beyond the code. You will start with environmental stewardship: what computers cost the planet (e-waste, energy, paper) and our health (posture, eyes, activity), the policies that reduce that harm, the ways computers help save resources through modelling and resource management, and the recyclers, refurbishers and programs that give old equipment a second life in Ontario and Canada.

Next you will tour emerging areas of computer science research: cryptography and security, artificial intelligence and data mining, robotics and computer vision, parallel and distributed computing, geographic information systems and human–computer interaction, and research that joins computer science with other fields such as biology, linguistics and climatology. Each tour includes a short Python program you can run and change. Then you will research one area yourself and report on it as a website, presentation or video.

Finally you will look ahead: career trends at the local, national and global levels, experiential learning such as co-op and job shadowing, supports for students choosing non-traditional paths, postsecondary programs (entrance requirements, length and costs), and the Essential Skills and Work Habits of the Ontario Skills Passport.

This unit uses the Python you learned in Programming Basics and Arrays and Subprograms, and connects to Software Development (design, Gantt charts, user-friendly interfaces) and Computer Environments and Systems (hardware, backups). Every lesson has explanations, worked examples, tested Python code, a hands-on activity, practice with answers and a quiz. You need a computer with Python 3 or a free browser-based Python editor, and internet access for the research activities.

Curriculum: The Ontario Curriculum, Grades 10 to 12: Computer Studies (2008), Introduction to Computer Science, Grade 11, University Preparation (ICS3U), strand D. Topics in Computer Science: D1.1 to D1.4 (environmental stewardship and sustainability), D2.1 to D2.3 (emerging areas of computer science research) and D3.1 to D3.5 (postsecondary education and career prospects).

63The Environmental Cost of Computing: E-Waste, Energy and Paper
70 min
D1.1
64Computers and Your Health: Ergonomics, Eye Strain and Balance
65 min
D1.1 D1.2
65Green Computing Policies: Rules That Reduce the Harm
65 min
D1.2
66Computers That Save Resources: Modelling, Simulation and Managing Nature
70 min
D1.3
67Where Old Computers Go: Recyclers, Refurbishers and Stewardship Programs
60 min
D1.4
68Cryptography and Security: Keeping Secrets with Mathematics
75 min
D2.1
69Artificial Intelligence, Machine Learning and Data Mining
75 min
D2.1
70Robotics, Computer Vision and Image Processing
70 min
D2.1
71Parallel and Distributed Computing: Many Processors, One Problem
65 min
D2.1
72Geographic Information Systems and Human–Computer Interaction
70 min
D2.1
73Computer Science Meets Other Fields: Interdisciplinary Research
70 min
D2.2
74Researching and Reporting on a Computer Science Topic
75 min
D2.3 D2.1 D2.2
75Careers in Computer Science: Trends Near and Far
65 min
D3.1
76Learning by Doing: Experiential Learning and Support Networks
65 min
D3.2 D3.4
77Postsecondary Pathways: Programs, Requirements and Costs
70 min
D3.3
78Essential Skills and Work Habits: The Ontario Skills Passport
60 min
D3.5
79Topics in Computer Science: Sustainability, Emerging Research and Careers: Unit Review
40 min
D1.1 D1.2 D1.3 D1.4 D2.1 D2.2 D2.3 D3.1 D3.2 D3.3 D3.4 D3.5

Curriculum strands

AProgramming Concepts and Skills

BSoftware Development

CComputer Environments and Systems

DTopics in Computer Science