Skip to content
Sabaqاردو

Intro to Computer Science with Python (Khan Academy)

By Khan Academy

Course audio
Course audio: English
Level
Beginner
Length
65 lessons · 5.5 hours

What you'll be able to do

  • Write Python programs using variables, input and conditionals
  • Repeat tasks with while and for loops
  • Organise code into functions and modules and test it
  • Use lists, dictionaries, classes and objects

About this course

Khan Academy's English introduction to programming through Python has 65 lessons and about 5.5 hours. It begins with what computer science is, print statements, tracing program execution and reading stack traces, then variables, user input and type casting. Control flow comes next: if, elif and else, compound boolean expressions, nested conditionals, while and for loops, break and continue. Later units cover functions and scope, creating modules, unit testing, lists, string methods, dictionaries and hashing, and finally classes, objects, encapsulation and composition. Many lessons are short program-design exercises such as a bus fare calculator or a Nim game. Suitable for absolute beginners, including school students.

Before you start: None

Syllabus

65 lessons · 5:32:27 in total

  1. 1Welcome to Intro to Computer Science - Python! | Intro to CS - Python | Khan Academy3:53
  2. 2What is computer science? | Intro to CS - Python | Khan Academy5:45
  3. 3Print statements and expressions | Intro to CS - Python | Khan Academy4:49
  4. 4Tracing program execution | Intro to CS - Python | Khan Academy5:08
  5. 5Debugging with stack traces | Intro to CS - Python | Khan Academy5:50
  6. 6Variables and assignment | Intro to CS - Python | Khan Academy4:44
  7. 7Tracing variables | Intro to CS - Python | Khan Academy5:47
  8. 8User input | Intro to CS - Python | Khan Academy4:13
  9. 9Program design: catering contract | Intro to CS - Python | Khan Academy4:17
  10. 10Type casting | Intro to CS - Python | Khan Academy4:05
  11. 11Tracing arithmetic expressions | Intro to CS - Python | Khan Academy5:31
  12. 12Algorithms and selection | Intro to CS - Python | Khan Academy4:07
  13. 13if statements | Intro to CS - Python | Khan Academy4:38
  14. 14Program design: bus fares | Intro to CS - Python | Khan Academy4:20
  15. 15Evaluating compound boolean expressions | Intro to CS - Python | Khan Academy4:36
  16. 16Program design: content moderation | Intro to CS - Python | Khan Academy4:49
  17. 17if-elif-else | Intro to CS - Python | Khan Academy4:46
  18. 18Program design: weights on Mars | Intro to CS - Python | Khan Academy5:25
  19. 19Nested conditionals | Intro to CS - Python | Khan Academy4:16
  20. 20Algorithmic bias | Intro to CS - Python | Khan Academy4:15
  21. 21Simulations and repetition | Intro to CS - Python | Khan Academy2:35
  22. 22Importing modules | Intro to CS - Python | Khan Academy4:24
  23. 23Program design: robot simulation | Intro to CS - Python | Khan Academy4:45
  24. 24while loops | Intro to CS - Python | Khan Academy4:29
  25. 25Tracing loop execution | Intro to CS - Python | Khan Academy4:56
  26. 26for loops with range() | Intro to CS - Python | Khan Academy4:23
  27. 27Program design: beehive simulation | Intro to CS - Python | Khan Academy5:54
  28. 28break and continue | Intro to CS - Python | Khan Academy5:16
  29. 29Games and modularity | Intro to CS - Python | Khan Academy4:04
  30. 30Functions | Intro to CS - Python | Khan Academy4:41
Show all 65 lessons
  1. 31Tracing function calls | Intro to CS - Python | Khan Academy5:34
  2. 32Local and global scope | Intro to CS - Python | Khan Academy4:56
  3. 33Nested function calls | Intro to CS - Python | Khan Academy6:23
  4. 34Program design: deck of cards | Intro to CS - Python | Khan Academy5:25
  5. 35Creating modules | Intro to CS - Python | Khan Academy4:26
  6. 36Program design: Nim game | Intro to CS - Python | Khan Academy5:55
  7. 37Unit testing | Intro to CS - Python | Khan Academy4:45
  8. 38Debugging with test cases | Intro to CS - Python | Khan Academy4:07
  9. 39Scripts and sequences | Intro to CS - Python | Khan Academy2:24
  10. 40Lists | Intro to CS - Python | Khan Academy4:01
  11. 41Tracing lists | Intro to CS - Python | Khan Academy5:58
  12. 42List iteration | Intro to CS - Python | Khan Academy4:54
  13. 43Program design: screen time | Intro to CS - Python | Khan Academy5:42
  14. 44String methods | Intro to CS - Python | Khan Academy5:28
  15. 45Pass by assignment | Intro to CS - Python | Khan Academy4:30
  16. 46Program design: flight delays | Intro to CS - Python | Khan Academy5:39
  17. 47Datasets and data structures | Intro to CS - Python | Khan Academy3:45
  18. 48Dictionaries | Intro to CS - Python | Khan Academy4:22
  19. 49Dictionary hashing | Intro to CS - Python | Khan Academy5:17
  20. 50Dictionary iteration | Intro to CS - Python | Khan Academy5:26
  21. 51Program design: bakery inventory | Intro to CS - Python | Khan Academy6:24
  22. 52Data modeling and APIs | Intro to CS - Python | Khan Academy4:17
  23. 53Accessing nested data | Intro to CS - Python | Khan Academy5:53
  24. 542D lists | Intro to CS - Python | Khan Academy6:31
  25. 55Program design: emergency response | Intro to CS - Python | Khan Academy6:26
  26. 56Software and abstraction | Intro to CS - Python | Khan Academy3:48
  27. 57Classes and objects | Intro to CS - Python | Khan Academy7:52
  28. 58Program design: search bar | Intro to CS - Python | Khan Academy6:47
  29. 59Methods and encapsulation | Intro to CS - Python | Khan Academy5:25
  30. 60Tracing objects | Intro to CS - Python | Khan Academy7:53
  31. 61Object equality | Intro to CS - Python | Khan Academy5:33
  32. 62Program design: course enrollment | Intro to CS - Python | Khan Academy6:02
  33. 63Object composition | Intro to CS - Python | Khan Academy5:21
  34. 64Program design: real estate | Intro to CS - Python | Khan Academy5:34
  35. 65Course tour for teachers | Intro to CS - Python | Khan Academy9:03

Questions

How long is this course?
It has 65 lessons and about 5.5 hours of video (5:32:27 in total). Your progress is saved lesson by lesson, so you can stop and continue on any device you sign in on, or in the same browser without signing in.
Is this course in English?
The lessons are taught in English. The teacher is Khan Academy; the videos play from their official YouTube channel, and Sabaq adds the lesson order, progress tracking, notes and the summary on this page.
Who is this course for, and what should I know first?
It is aimed at beginners: it starts from the basics. Before you start: None.
Is it free, and do I need an account?
Yes, it is free to watch and no account is needed. The videos are official uploads by the teacher on YouTube; a free DanixSoft account is optional and only syncs your progress between devices.
What should I take after this course?
A good next step on Sabaq is “Harvard CS50x: Introduction to Computer Science”. The “What to take next” list on this page shows more courses at the same or a higher level in the same topic.

What to take next

Videos by Khan Academy, played from their official YouTube channel. Subscribe on YouTube

Official upload by the teacher or institution on their own channel, shown with YouTube's embedded player.

Lessons listed from the official YouTube playlist. Full playlist on YouTube

Lessons last checked Nov 2026. Course summary and lesson structure by Sabaq.

Report a problem or a rights request