LECTURES A GRATIS GLOBAL SERVICE
⌕ SEARCH GRATIS GLOBAL ↗
LECTURES / COMPUTER SCIENCE
Lecture 21: Timing Programs and Counting Operations
SOURCE: YOUTUBE · NO YOUTUBE TRACKING UNTIL YOU PRESS PLAY · TROUBLE PLAYING? WATCH AT THE SOURCE ↗

Lecture 21: Timing Programs and Counting Operations

32 MIN · EN · STATUS: [ STREAMING ]
RATE THIS
MIT · Introduction to CS and Programming using Python · LECTURE 21

At a glance

Ana Bell teaches this lecture from MIT's 6.100L, Introduction to CS and Programming using Python, on how to evaluate the efficiency of a program. She covers using a timer to measure actual running time, why wall-clock timing is unreliable for comparing algorithms, and the alternative approach of counting the number of basic operations a program performs as its input grows. The lecture builds toward abstracting these operation counts into order of growth, laying groundwork for later discussion of big-O notation. Bell works through code examples on the board and screen, showing how different implementations of the same task scale differently as input size increases. The session is part of the Fall 2022 offering of 6.100L and assumes familiarity with basic Python programming from earlier lectures in the course.

At a glance

Lecture facts

Runtime compared with the other 1,354 Mathematics lectures
Runtime32 m
Compared with MathematicsShorter than 88%
Link status✓ Working · checked yesterday
This series

Introduction to CS and Programming using Python

Every lecture in order, sized by its length.

  • Earlier lectures
  • This lecture
  • Still to come
Lecture 21 of 25 21 h 15 m before this · 26 h 30 m in total

More from this course

12 LECTURES
Introduction to CS and Programming Using Python: Lecture 1

Introduction to CS and Programming Using Python: Lecture 1

MIT · 64 MIN
Strings, Input/Output, and Branching

Strings, Input/Output, and Branching

MIT · 79 MIN
Lecture 3: Iteration

Lecture 3: Iteration

MIT · 47 MIN
Lecture 4: Loops over Strings, Guess-and-Check, and Binary

Lecture 4: Loops over Strings, Guess-and-Check, and Binary

MIT · 73 MIN
Lecture 5: Floats and Approximation Methods

Lecture 5: Floats and Approximation Methods

MIT · 47 MIN
Lecture 6: Bisection Search

Lecture 6: Bisection Search

MIT · 74 MIN
Decomposition, Abstraction, and Functions

Decomposition, Abstraction, and Functions

MIT · 46 MIN
Functions as Objects

Functions as Objects

MIT · 78 MIN
Lecture 9: Lambda Functions, Tuples, and Lists

Lecture 9: Lambda Functions, Tuples, and Lists

MIT · 45 MIN
Lecture 10: Lists and Mutability

Lecture 10: Lists and Mutability

MIT · 75 MIN
Lecture 11: Aliasing and Cloning

Lecture 11: Aliasing and Cloning

MIT · 46 MIN
Lecture 12: List Comprehension, Functions as Objects, Testing, and Debugging

Lecture 12: List Comprehension, Functions as Objects, Testing, and Debugging

MIT · 76 MIN