Premium Only Content

CS50P - Lecture 6 - File I O
TABLE OF CONTENTS
00:00:00 - Introduction
00:00:24 - File I/O
00:01:17 - lists
00:05:54 - open
00:13:55 - with
00:21:39 - sorted
00:29:31 - Comma-Separated Values
00:46:37 - Sort Keys
00:53:01 - Lambda Functions
00:57:13 - csv Library
01:02:17 - csv.reader
01:07:49 - csv.DictReader
01:14:05 - csv.writer
01:16:28 - csv.DictWriter
01:23:00 - Images, PIL library
01:31:42 - Conclusion
An introduction to programming using a language called Python. Learn how to read and write code as well as how to test and "debug" it. Designed for students with or without prior programming experience who'd like to learn Python specifically. Learn about functions, arguments, and return values (oh my!); variables and types; conditionals and Boolean expressions; and loops. Learn how to handle exceptions, find and fix bugs, and write unit tests; use third-party libraries; validate and extract data with regular expressions; model real-world entities with classes, objects, methods, and properties; and read and write files. Hands-on opportunities for lots of practice. Exercises inspired by real-world programming problems. No software required except for a web browser, or you can write code on your own PC or Mac.
Whereas CS50x itself focuses on computer science more generally as well as programming with C, Python, SQL, and JavaScript, this course, aka CS50P, is entirely focused on programming with Python. You can take CS50P before CS50x, during CS50x, or after CS50x. But for an introduction to computer science itself, you should still take CS50x!
-
58:33
The Dan Bongino Show
2 hours agoAmerica's A-Team Hits The Ground Running (Ep. 2432) - 02/27/2025
226K499 -
The Rubin Report
1 hour agoCNN Host Brutally Mocked for Trying to Profit Off of What He Called a ‘Conspiracy’
6.84K11 -
LIVE
Benny Johnson
17 hours ago🚨BREAKING: Epstein List, Flight Logs RELEASED Any Minute By Trump | ELITES IN PANIC
18,914 watching -
2:10:17
Steven Crowder
3 hours agoEpstein File Watch & DOGE’s $17M Muppet Show Explained
221K210 -
1:04:22
Timcast
2 hours agoTrump Orders ALL TRANS MILITARY Discharged, Trans Person CAUGHT With BOMBS At Tesla Dealership
44.6K58 -
LIVE
LFA TV
16 hours agoPAYBACK = JUSTICE! | LIVE FROM AMERICA 2.27.25 11AM
4,989 watching -
DVR
Bannons War Room
9 days agoWarRoom Live
2.32M410 -
2:17:39
Matt Kohrs
11 hours agoBREAKING MARKET NEWS: Bounce or Bust?! || The MK Show
33.1K1 -
47:26
BonginoReport
4 hours agoEpstein Files Drop Today-But How Much Will They Reveal? (Ep.149) - 02/27/2025
94.8K128 -
2:59:16
Wendy Bell Radio
7 hours agoThe Left Is Wrong About Everything
71.2K45