← Free Learning Library · Programming

Programming

CS50's Introduction to Programming with Python (CS50P) 2022

Learn Python from scratch with Harvard's CS50P course, covering functions, loops, exceptions, libraries, unit tests, file I/O, regex, and object-oriented programming.

Learn from: the original creator. Original content published on YouTube. DigitalSkillX organizes these public resources into a structured learning path. DigitalSkillX does not claim ownership or partnership.

Lessons
11
Time
About 15 hr 54 min
Level
beginner

Now playing: CS50P - Lecture 8 - Object-Oriented Programming

About this path

This learning path follows the CS50P 2022 playlist, a free introduction to programming using Python. You'll start with the basics like functions and variables, then move through conditionals, loops, and exceptions. Later lectures cover using third-party libraries, writing unit tests, reading and writing files, validating data with regular expressions, and modeling real-world entities with classes and objects. The course is designed for beginners with no prior programming experience, but also works for those who want to learn Python specifically. You only need a web browser, or you can write code on your own computer.

What you will learn

  • Understand core Python syntax: functions, variables, conditionals, loops, and exceptions
  • Use third-party libraries and handle file input/output
  • Write and run unit tests to verify your code
  • Apply regular expressions for data validation and extraction
  • Design and use classes, objects, methods, and properties
  • Practice with hands-on exercises inspired by real-world problems

Who this is for

Beginners who want a structured free introduction before deeper practice.

Curriculum

Section 1: Getting Started

  1. Lesson 1: CS50P - Introduction

    This is the course introduction. It explains what CS50P is, how to enroll for free, and where to find slides and source code. It also outlines the topics you'll cover, from functions and variables to classes and file I/O.

    Open on YouTube
  2. Lesson 2: CS50P - Lecture 0 - Functions, Variables

    Lecture 0 covers the basics of Python: functions, arguments, return values, variables, and types. You'll write your first programs and learn how to use the print function and handle user input.

    Open on YouTube

Section 2: Control Flow and Error Handling

  1. Lesson 3: CS50P - Lecture 1 - Conditionals

    Lecture 1 introduces conditionals and Boolean expressions. You'll learn how to use if, elif, and else statements to make decisions in your code, and how to compare values.

    Open on YouTube
  2. Lesson 4: CS50P - Lecture 2 - Loops

    Lecture 2 covers loops, including while and for loops. You'll learn how to repeat actions, iterate over sequences, and use range and other loop controls.

    Open on YouTube
  3. Lesson 5: CS50P - Lecture 3 - Exceptions

    Lecture 3 explains exceptions and how to handle errors gracefully. You'll learn about try and except blocks, and how to catch and respond to runtime errors.

    Open on YouTube

Section 3: Libraries and Testing

  1. Lesson 6: CS50P - Lecture 4 - Libraries

    Lecture 4 is about libraries. You'll learn how to import and use third-party libraries, and explore some built-in modules like random, statistics, and sys.

    Open on YouTube
  2. Lesson 7: CS50P - Lecture 5 - Unit Tests

    Lecture 5 focuses on unit tests. You'll learn how to write tests for your functions using pytest, and why testing is important for reliable code.

    Open on YouTube

Section 4: Data and Patterns

  1. Lesson 8: CS50P - Lecture 6 - File I/O

    Lecture 6 covers file I/O. You'll learn how to read from and write to files, work with CSV files, and handle data persistence.

    Open on YouTube
  2. Lesson 9: CS50P - Lecture 7 - Regular Expressions

    Lecture 7 introduces regular expressions. You'll learn how to use the re module to validate and extract data from strings, and how to build patterns for common tasks.

    Open on YouTube

Section 5: Advanced Topics and Wrap-Up

  1. Lesson 10: CS50P - Lecture 8 - Object-Oriented Programming

    Lecture 8 covers object-oriented programming. You'll learn how to define classes, create objects, use methods and properties, and model real-world entities.

    Open on YouTube
  2. Lesson 11: CS50P - Lecture 9 - Et Cetera

    Lecture 9, titled 'Et Cetera', covers additional Python features and best practices. Topics include set operations, global constants, type hints, and documentation strings.

    Open on YouTube

Your progress

0 of 11 lessons marked complete (0%). Progress stays on this device until you choose to get a certificate.