Academic Catalog


Foothill College Course Outline of Record

Foothill College Course Outline of Record
Heading Value
Effective Term: Summer 2023
Units: 4.5
Hours: 4 lecture, 2 laboratory per week (72 total per quarter)
Prerequisite: C S 3A.
Advisory: Demonstrated proficiency in English by placement via multiple measures OR through an equivalent placement process OR completion of ESLL 125 & ESLL 249.
Degree & Credit Status: Degree-Applicable Credit Course
Foothill GE: Non-GE
Transferable: CSU/UC
Grade Type: Letter Grade (Request for Pass/No Pass)
Repeatability: Not Repeatable

Student Learning Outcomes

  • A successful student will be able to use the Python environment to define the basic abstract data types (stacks, queues, lists) and iterators of those types to effectively manipulate the data in his or her program.
  • A successful student will be able to write and debug Python programs which make use of inheritance, i.e., the "is a" relationship, common to all OOP languages. Specifically, the student will define base and derived classes and use common techniques such as method chaining in his or her programs.


Systematic treatment of intermediate concepts in computer science through the study of Python object-oriented programming (OOP). Coding topics include Python sequences, user-defined classes and interfaces, modules, packages, collection classes, threads, lambda expressions, list comprehensions, regular expressions and multi-dimensional arrays. Concept topics include OOP project design, recursion, inheritance, polymorphism, functional programming, linked-lists, FIFOs, LIFOs, event-driven parsing, exceptions, and guarded code.

Course Objectives

The student will be able to:

  1. Configure a Python Development Environment for advanced Python programming
  2. Use both instance members and class members, as appropriate, in class design
  3. Analyze and demonstrate the use of multi-dimensional arrays in Python
  4. Design, implement, and test Python programs that use class inheritance/specialization, and explain why this is an example of the "is-a" relationship
  5. Demonstrate the use of advanced functional programming
  6. Explain how guarded code is implemented in Python through exceptions
  7. Express numbers in decimal, binary, and hexadecimal representations, and use bitwise logical operators to process data at the bit and byte level
  8. Demonstrate a working knowledge of basic abstract data types and their Python-based collection classes
  9. Produce end-user programs which feature event-driven techniques and multi-threading to provide a sensible and easy-to-use GUI
  10. Explain what a Python abstract base class (ABC) is and how it is used
  11. Describe declaration models for run-time storage allocation, garbage collection, and type checking, and compare with other languages like C++ or Java
  12. Use some of the Python collections to write efficient and portable application programs
  13. Write to and read from files using intermediate file I/O operations in a Python program
  14. Design, implement, test, and debug intermediate-level Python programs that use each of the following fundamental programming constructs: string processing, numeric computation, simple I/O, arrays, and the Python API
  15. Write applications that solve problems in one or more application area: mathematics, physics, chemistry, cellular automata, 3-D simulation, astronomy, biology, business, internet

Course Content

  1. Setting up a complete Python environment
    1. Using the website
    2. Configuring the PATH and other environment variables
  2. The proper use of class and instances members and methods
    1. Class attributes
    2. Instance attributes
    3. Scope and namespace usage of class and instance attributes
    4. Modules vs. classes
    5. Comparison of instance, class, and static methods
    6. Deep vs. shallow copies with copy() and deepcopy()
    7. Operator overloading
  3. Multi-dimensional arrays and the NumPy Module
    1. Multi-dimensional arrays using lists of list
    2. Multi-dimensional arrays using NumPy
    3. Limitations of Python array class
    4. List iterators vs. explicit index values
    5. Binary searching as a logarithmic time complexity example of recursion
  4. Inheritance
    1. The "is a" relationship
    2. Extending existing base classes
    3. Derived classes (subclasses) and class hierarchy
    4. Member method overriding
    5. Intended private, public, and default members
    6. Encapsulation and Polymorphism
  5. Advanced OOP
    1. Constructor chaining
    2. Member method chaining
    3. Key (named) parameters
  6. Error handling and event-driven programming
    1. Built-in Python exception objects
    2. Custom exception declarations
    3. Manually raising exceptions
    4. Alternatives to exceptions
  7. Non-decimal arithmetic and related types
    1. Bitwise numeric operators
    2. Bitwise logical operators
    3. Binary and hexadecimal constants
    4. Enum types (int and non-int)
  8. Container datatypes
    1. Abstract Data Types (ADTs) and Python Collections
    2. List-like, dict-like, and wrapper containers
    3. The vector and linked-list ADT and Python's deque objects
    4. The "hash-able" ADT and Python's Counter objects
    5. Implementing ADTs through inheritance
  9. Topics in Graphical User Interfaces (GUI) and multi-threading
    1. GUI through Tkinter module
    2. Tkinter widgets (message, button, label, text, canvas)
    3. Layout options (pack, grid)
    4. Event handlers: built-in vs. custom
    5. Multi-threaded using the Python library
  10. Abstract Base Classes (ABCs)
    1. Metaclass for defining ABCs
    2. Defining and using interfaces
  11. Storage allocation models and typing in Python
    1. Python memory management, symbol tables, and execution model
    2. Run time object binding and storage management of activation records in Python
    3. Binding, visibility, persistence, and lifetime of variables
    4. Strong typing vs. dynamic typing
    5. Duck typing vs. isinstance() and hasattr()
  12. Specifics of Python Collections
    1. The namedtuple() method
    2. Deque used to implement queue and stack
    3. Counter for rapid tallies
    4. Defaultdict for key-value pairs and lists
  13. Topics in Python file I/O
    1. Output formatting
    2. File objects
    3. JSON use in Python
  14. Essential examples and assignment areas in Python
    1. String/text processing
    2. Numeric computation
    3. User interaction
    4. Multi-class projects and compound data types
    5. Inheritance-based projects
    6. Representative GUI and/or threaded project with event-driven design
  15. Applications used throughout course in selected areas
    1. Math
    2. Physics
    3. Chemistry
    4. Biology
    5. Astronomy
    6. Business and finance
    7. Internet

Lab Content

  1. Familiarization with the intermediate-level online development environment
    1. Modify and customize the environment variables that affect the Python installation
    2. Create multi-file programming projects
    3. Gain experience with the steps needed to edit a complex program
    4. Modify editor settings to produce an industry standard code style
  2. Organizing and debugging multi-class projects
    1. Demonstrate the ability to debug programs that contain multiple classes
    2. Distinguish between interface and implementation in projects by creating classes that are independent of I/O modality
    3. Write individual component classes that are independent of client use and can serve several client programs
    4. Emulate symbolic constants by not providing setters
    5. Implement static and instance members into classes in a way that demonstrates a mature understanding of object-oriented programming (OOP) in a lab project
  3. Exploring advanced array constructs in class design
    1. Gain experience in effectively using single and multi-dimensional arrays as class members
    2. Apply nested loops to process multi-dimensional arrays
    3. Use the Python environment to debug errors in multi-dimensional arrays
    4. Solve problems using fixed-size and dynamic sized arrays, as appropriate
  4. Demonstrating competence in intermediate level algorithm design using classes within the Python environment
    1. Use Python tools and text editors to implement a multi-faceted algorithm and/or simulation that makes effective use of OOP
    2. Evaluate and comment on other students' algorithms
    3. Utilize a combination of string processing and numeric processing to address various aspects of the algorithm implementation
    4. Produce clear program runs which demonstrate that the algorithm addresses a variety of cases and/or input states
    5. Incorporate bitwise and logical operations to address binary logic tasks within an algorithm
  5. Building a program that uses class inheritance to demonstrate how re-use is handled in OOP
    1. Create a project that contains at least one class intended to be used as a base class
    2. Derive (sub-class) one or more classes from the base class
    3. Use method overriding to avoid code duplication between base classes and derived classes
  6. Incorporating basic abstract data types in programming projects
    1. Implement a fundamental abstract data type (ADT), such as a queue or stack in a programming lab
    2. Use a previously written ADT from the Python's collection application programmer interface (API)
    3. Incorporate inheritance in a project that uses ADTs
    4. Provide a client program that tests and demonstrates the correct behavior of the ADT
  7. The proper use of modules and classes, in conjunction with inheritance and other advanced techniques learned in previous labs
    1. Create the proper set of methods within a class that enables an object to be copied deeply
    2. Utilize inheritance to reinforce the segregation of data into base- and derived-level behavior
    3. Utilize at least one other lab concept, such as binary logic or multi-dimensional arrays, to further improve integration of intermediate concepts
    4. Separate I/O and data storage in advanced programs
  8. Building projects that make effective use of Python's duck typing
    1. Demonstrate the difference between deriving from a base class and specializing using duck typing
    2. Practice using a duck typed method or class by invoking the method with different client types and test that the duck typing is working as expected
    3. Use duck typing to exercise some aspect of ADTs, such as specializing a generic ADT to make its behavior specific to an assigned project specification
    4. Employ debugging techniques to solve problems that arise when designing with duck typing
  9. Exception handling and file I/O in programming
    1. Write a class that has methods which use exception handling to report errors to the client
    2. Write a test client that uses a try/except template to detect exceptions
    3. Implement an algorithm or simulation that reads from and/or writes to external files
    4. Demonstrate various ways that exceptions are handled and reported besides exception objects being raised and excepted

Special Facilities and/or Equipment

1. Access to a computer laboratory with Python interpreters.
2. Website or course management system with an assignment posting component (through which all lab assignments are to be submitted) and a forum component (where students can discuss course material and receive help from the instructor). This applies to all sections, including on-campus (i.e., face-to-face) offerings.
3. When taught via Foothill Global Access on the internet, the college will provide a fully functional and maintained course management system through which the instructor and students can interact.
4. When taught via Foothill Global Access on the internet, students must have currently existing email accounts and ongoing access to computers with internet capabilities.

Method(s) of Evaluation

Methods of Evaluation may include but are not limited to the following:

Tests and quizzes
Written laboratory assignments which include source code, sample runs, and documentation
Final examination

Method(s) of Instruction

Methods of Instruction may include but are not limited to the following:

Lectures which include motivation for syntax and use of the Python language and OOP concepts, example programs, and analysis of these programs
Online labs (for all sections, including those meeting face-to-face/on-campus), consisting of:
1. A programming assignment webpage located on a college-hosted course management system or other department-approved internet environment. Here, the students will review the specification of each programming assignment and submit their completed lab work
2. A discussion webpage located on a college-hosted course management system or other department-approved internet environment. Here, students can request assistance from the instructor and interact publicly with other class members
Detailed review of programming assignments which includes model solutions and specific comments on the student submissions
In-person or online discussion which engages students and instructor in an ongoing dialog pertaining to all aspects of designing, implementing, and analyzing programs
When course is taught fully online:
1. Instructor-authored lecture materials, handouts, syllabus, assignments, tests, and other relevant course material will be delivered through a college-hosted course management system or other department-approved internet environment
2. Additional instructional guidelines for this course are listed in the attached addendum of CS department online practices

Representative Text(s) and Other Materials

Ramalho, Luciano. Fluent Python. 2022.

Downey, Allen. Think Python, 2nd ed.. 2020.

Types and/or Examples of Required Reading, Writing, and Outside of Class Assignments

  1. Reading
    1. Textbook assigned reading averaging 30 pages per week
    2. Reading the supplied handouts and modules averaging 10 pages per week
    3. Reading online resources as directed by instructor though links pertinent to programming
    4. Reading library and reference material directed by instructor through course handouts
  2. Writing
    1. Writing technical prose documentation that supports and describes the programs that are submitted for grades


Computer Science