CS50x 2024 - Lecture 6 - Python

  Рет қаралды 274,810

CS50

CS50

Күн бұрын

***
This is CS50, Harvard University's introduction to the intellectual enterprises of computer science and the art of programming.
***
TABLE OF CONTENTS
00:00:00 - Introduction
00:01:01 - Python
00:07:24 - Speller
00:13:41 - Filter
00:17:31 - Face Recognition
00:20:53 - Functions
00:33:24 - Types
00:34:47 - Calculator
00:44:45 - Conditionals
00:48:05 - Compare
00:57:18 - Object-Oriented Programming
01:02:54 - Loops
01:13:51 - Meow
01:21:20 - Truncation
01:25:54 - Exceptions
01:33:22 - Mario
01:39:44 - Lists
01:49:18 - Dictionaries
01:59:58 - sys
02:04:04 - pip
***
HOW TO SUBSCRIBE
kzbin.info_c...
HOW TO TAKE CS50
edX: cs50.edx.org/
Harvard Extension School: cs50.harvard.edu/extension
Harvard Summer School: cs50.harvard.edu/summer
OpenCourseWare: cs50.harvard.edu/x
HOW TO JOIN CS50 COMMUNITIES
Discord: / discord
Ed: cs50.harvard.edu/x/ed
Facebook Group: / cs50
Faceboook Page: / cs50
GitHub: github.com/cs50
Gitter: gitter.im/cs50/x
Instagram: / cs50
LinkedIn Group: / 7437240
LinkedIn Page: / cs50
Medium: / cs50
Quora: www.quora.com/topic/CS50
Reddit: / cs50
Slack: cs50.edx.org/slack
Snapchat: / cs50
SoundCloud: / cs50
Stack Exchange: cs50.stackexchange.com/
TikTok: / cs50
Twitter: / cs50
KZbin: / cs50
HOW TO FOLLOW DAVID J. MALAN
Facebook: / dmalan
GitHub: github.com/dmalan
Instagram: / davidjmalan
LinkedIn: / malan
Quora: www.quora.com/profile/David-J...
TikTok: / davidjmalan
Twitter: / davidjmalan
***
CS50 SHOP
cs50.harvardshop.com/
***
LICENSE
CC BY-NC-SA 4.0
Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License
creativecommons.org/licenses/...
David J. Malan
cs.harvard.edu/malan
malan@harvard.edu

Пікірлер: 147
@justanothernothuman
@justanothernothuman Ай бұрын
"Malloc is gone, pointers are gone, free is gone!" thanks to the lord !
@jeannoelhonisch7037
@jeannoelhonisch7037 Ай бұрын
100%
@kennessu4642
@kennessu4642 29 күн бұрын
used to pray for times like these
@VIPER_12328
@VIPER_12328 6 күн бұрын
Same lol
@pratyush842
@pratyush842 5 сағат бұрын
My dream
@jrb65
@jrb65 4 ай бұрын
What an amazing professor. Not a single boring moment .
@harshgawali5154
@harshgawali5154 5 ай бұрын
The ending was damn! 😂 well done CS50
@sefonefinpsefnpefn4191
@sefonefinpsefnpefn4191 4 ай бұрын
I like it!❤
@neclis7777
@neclis7777 3 ай бұрын
Incredible teacher, as much a stand up performer as an expert in his field. What energy he puts in his work ...
@FarizDarari
@FarizDarari 4 ай бұрын
It's mindblowing how a course video with such content quality is free. Thanks, huge thanks, CS50!
@Zachattack0_0
@Zachattack0_0 4 ай бұрын
Well, remember, to get a certificate costs about $200. So the course is free to access, but they are certainly making their money back with the number of certifications they give out!
@AA-cy9ib
@AA-cy9ib 3 ай бұрын
@@Zachattack0_0 Not true! They also give free certificates which are almost as valuable as paid ones.
@Zachattack0_0
@Zachattack0_0 3 ай бұрын
​@@AA-cy9ib Where? AFAIK you have to pay for an official Harvard CS50 certificate.
@ihavermsthattypeofbrain8377
@ihavermsthattypeofbrain8377 23 күн бұрын
​@@Zachattack0_0not really. I think when you go to Harvard edu it's available. It actually have same value as the $200 one
@AskforQAli
@AskforQAli 5 ай бұрын
Happy New year to you all!! May 2024 be the best year for your personal growth
@brooksgunn5235
@brooksgunn5235 5 ай бұрын
Ah, the endings are always funny and uplifting!
@emiliosaliba8320
@emiliosaliba8320 11 сағат бұрын
Best IT proffessor i ever had, amazing explanations , dinamic, thanx a lot from a poor southamerican
@mtarik0
@mtarik0 4 ай бұрын
57:18 What a beautiful way to explain what OOP is in basic terms!
@bekay7663
@bekay7663 4 ай бұрын
it might because of my little knowledge of OOP previously before starting the course or the Weeks leading up, but in that 5 minute segment I fully understand object oriented programming, or at least have a solid grasp of it.
@mtarik0
@mtarik0 4 ай бұрын
That's awesome! I do believe that playing around with C language first makes the transition much better. I started learning programming with Java, and even though our instructors explained us the OOP term in similar ways, we as learners sort of took it for granted. It was because we didn't know what it was like a variable not having built-in functionalities, its advantages, etc. This is why I love CS50 :) Since you feel like as such, you will probably have an easy time of understanding encapsulation, inheritance and the like, best of luck! @@bekay7663
@bassycounter
@bassycounter 2 ай бұрын
“I apologize if you’re harboring resentment that this wasn’t a week earlier” 😂It’s okay professor, I have accepted that to understand programming and computer science better, I must dive into lower level stuff occasionally, week 5 was tough but I persevered!
@xiaoyangshawnhuang1251
@xiaoyangshawnhuang1251 4 ай бұрын
Just amazing lecture, love it, well done!
@angelofinassu4867
@angelofinassu4867 3 ай бұрын
Finally python friends, I discovered CS wold through python years ago, but now with a university, it's very rewarding to go back to studying once again
@pranshuatrey
@pranshuatrey 19 күн бұрын
What a perfect ending
@DeshBhakt588
@DeshBhakt588 4 ай бұрын
Super energy 😊
@hedgehog_hey
@hedgehog_hey 2 ай бұрын
TKS U ! CS50 , and the professor Malan Miller!🥰
@Ubiselfs
@Ubiselfs 3 ай бұрын
Man I love this guy
@prjerry7777
@prjerry7777 3 ай бұрын
He is an excellent teacher.
@user-si4tb7cr9t
@user-si4tb7cr9t 2 ай бұрын
lovely class, extraordinary
@hhhhh00000
@hhhhh00000 5 ай бұрын
Wish i had just one teacher like David Malan or Brian Yu in my entire education journey . :-)
@user-ji9gq3pu1d
@user-ji9gq3pu1d Ай бұрын
What an amazing lecture and it is so brilliant to teach C first and then move to Python. After all that C, Python will be gravy train!
@aopen130
@aopen130 2 ай бұрын
can't wait for Javascript lecture so it will break everything we learned here.
@jiffy5210
@jiffy5210 17 күн бұрын
the ending was great !!
@zahidsayil9066
@zahidsayil9066 4 ай бұрын
love the energy
@user-bs9hz1eu7s
@user-bs9hz1eu7s 4 ай бұрын
oh wow!! one of the best python video to learn
@sefonefinpsefnpefn4191
@sefonefinpsefnpefn4191 4 ай бұрын
finally python 🎉❤
@user-jc7md5mi4g
@user-jc7md5mi4g 4 ай бұрын
Дякую! 🙂
@willperry1147
@willperry1147 Ай бұрын
Blessed thank you
@user-fe4ru2op1x
@user-fe4ru2op1x Ай бұрын
From EGYPT THIS IS GREAT❤
@Dragon4526
@Dragon4526 5 ай бұрын
Another year, Another CS50
@symbolminded5167
@symbolminded5167 Күн бұрын
Keep grinding boys
@hasirash6786
@hasirash6786 3 ай бұрын
Ending was so funny lol
@shinthantkaung
@shinthantkaung Ай бұрын
GOD BLESS YOU!!!!!!
@ryokudoom
@ryokudoom 21 күн бұрын
Can't believe i got rickrolled when rolling into my coding class
@Serhii007
@Serhii007 5 ай бұрын
Дякую!
@zsunnder2355
@zsunnder2355 16 күн бұрын
Best Ending🤣🤣
@eleos11
@eleos11 2 ай бұрын
When I watch David's lectures I like to follow copying the code. However, here I wonder where are all those files like speller.py reside, so that I could use them. Is there a repository of some sort? Any ideas?
@Mustafa_Tahaha
@Mustafa_Tahaha 5 ай бұрын
Struggling through C to reach the holy grail that is Python!
@radman999
@radman999 5 ай бұрын
Would be better off sticking with C and C++ instead of a bloatware script language that anyone's mom can do
@mclaren720
@mclaren720 5 ай бұрын
@@radman999how many years have you been coding?
@Rayer24
@Rayer24 5 ай бұрын
@@radman999
@asadelh.28
@asadelh.28 5 ай бұрын
​@@radman999bloatware script language thats one of the most popular and most used languages in the world, way more than C and C++ and that basically has a monopoly over AI. Youre one of those smooth brains who thinks theyre smart because somehow using verbose languages compensates for your inherent lack of programming skill
@user-mo9bc8lo6b
@user-mo9bc8lo6b 4 ай бұрын
Monty PYTHON
@javanatto
@javanatto 4 ай бұрын
Oh, my! We've got rickrolled...again. what a perfect ending for a lecture, that's the perfect description XD
@chinmayachidrewar8856
@chinmayachidrewar8856 3 ай бұрын
you ruined it for me🥲
@bx7gamer
@bx7gamer 3 ай бұрын
Can someone please list all the modules (pip) installed during the course! ,thanks in advance
@aopen130
@aopen130 2 ай бұрын
`pip list` in the command prompt. if it doesn't work, make sure the virtual environment is in your PATH you can learn more about syntax for pip list command with `python -m pip list`
@wonkanese
@wonkanese 5 ай бұрын
I can feel David Malan's energy
@quangluu79
@quangluu79 5 күн бұрын
👍👍👍
@zikeng5444
@zikeng5444 3 ай бұрын
There's no goddamn way we got rickrolled by harvard university
@Jonathanmillspatrick
@Jonathanmillspatrick Ай бұрын
Is there a rationale for the extra spacing, two blank lines, between code?
@brandy9725
@brandy9725 Ай бұрын
David explains at 1:27:08 that it's a convention to help make functions stand out
@user-dz8me4sp8m
@user-dz8me4sp8m 12 күн бұрын
The dictionary part is a littlebit tough haha.. there are crazy syntax like what he said
@tiagoantonio2343
@tiagoantonio2343 3 күн бұрын
I LOVE PYTHON
@spodi4real
@spodi4real 4 ай бұрын
how come i did not know about this amazing thing called cs50 I regret every second in my life i didn't know about this!!
@kitgary
@kitgary 5 ай бұрын
Can we have a CS50 lesson teaching how to crack the programming interview?
@fakrulotaku5655
@fakrulotaku5655 11 күн бұрын
The ending 😂😂
@jesuscarrillo7411
@jesuscarrillo7411 4 ай бұрын
Great
@kenyhu4759
@kenyhu4759 3 ай бұрын
Good day
@airkh.
@airkh. 2 ай бұрын
the rickroll at the end lmaoo
@georgimmitev
@georgimmitev 4 күн бұрын
1:15:24
@grindinguy
@grindinguy 4 ай бұрын
i knew it but im rickrolled too :)
@ShahbazG
@ShahbazG 27 күн бұрын
problem set? 🤔
@mfbbbbbbbbbbbbbbbbbb
@mfbbbbbbbbbbbbbbbbbb Ай бұрын
Greatest rickroll 2024
@randomenia
@randomenia 4 ай бұрын
I don't speak english I'm watching whit Subtitule I have 16 years old You're The Best sorry for error
@nazmulalam7125
@nazmulalam7125 3 ай бұрын
Melan. How are YOU?
@fakrulotaku5655
@fakrulotaku5655 11 күн бұрын
2:03:52 is kinda hilarious 😂
@PhilipDenys
@PhilipDenys 4 ай бұрын
dude is mark rover's brother :D
@elijahsalarda6497
@elijahsalarda6497 11 күн бұрын
i think i will like python haha 🤤
@d.k.1545
@d.k.1545 5 ай бұрын
question; at 1:56:55 David is making the dictionary caleld people, but he never defines the name person. Yet below that person exists anyway? Why not just do; for name in people: instead and skip the next line ?
@d.k.1545
@d.k.1545 5 ай бұрын
or does he just use person instead of the generic n variable like _ ?
@VijayGandhinagar
@VijayGandhinagar 4 ай бұрын
At 1:56:55, the variable "person" is a list of dictionaries, and not a list of strings or integers. Hence you have to access the dictionary first and then look/check if the dictionary has that name, for each dictionary in the list.
@d.k.1545
@d.k.1545 4 ай бұрын
@@VijayGandhinagar thanks for your reply! really appreciate it. However my question is more so that he doesn't define or initiate a variable or typedef called person and suddenly uses it as for person in (dictionary set name) so it it just an n variable here?
@d.k.1545
@d.k.1545 4 ай бұрын
Having watched the section I understand it now. as I assumed it's basically an initialized variable with the chosen name person, and it's looking for the input name in the dictionary key of name
@henriktandberg9899
@henriktandberg9899 4 ай бұрын
@@d.k.1545 The "person" variable in this case is just like the i in for loops conventionally used in C. It's just a more describing name for the variable doing the counting of each iteration of the loop. I was a bit confused by this as well, but David could have used i or _ as he mentioned earlier and had the same result. He just chose person as it was iterating through dicts of people.
@boks02_
@boks02_ 2 ай бұрын
malloc(); is GONE 🗿free(); is GONE🗿*pointers are GONE🗿
@harisuresh2507
@harisuresh2507 2 ай бұрын
im sold on python rn
@wonkanese
@wonkanese 5 ай бұрын
Give me that
@tahmidnewaz3082
@tahmidnewaz3082 5 ай бұрын
Did I just get Rickrolled?
@mk810
@mk810 23 күн бұрын
Anyone else kind of recognize that URL by now? 😆
@juli.72
@juli.72 2 ай бұрын
got me with the rick roll
@fayzullohkarimov48
@fayzullohkarimov48 19 күн бұрын
Like if you never skip intro mucis
@waffle6579
@waffle6579 2 ай бұрын
I hope professor Malan can cosplay prison Mike.
@karacg
@karacg 5 ай бұрын
who can learn all this any Prior Experienced
@MrMfrk
@MrMfrk 5 ай бұрын
old lecture is posted here in 2024
@HolyHaddock
@HolyHaddock 5 ай бұрын
You mean that this is the 2023 lecture? Sorry me English bad
@farhanarahman9375
@farhanarahman9375 4 ай бұрын
nope this is the lecture for 2024
@ShubhamJha-rl9ss
@ShubhamJha-rl9ss Ай бұрын
who else got rick rolled ?
@syedzainulabideen4455
@syedzainulabideen4455 5 ай бұрын
1like = 5pushups in 2024
@user-go.pro1
@user-go.pro1 5 ай бұрын
Hi!!!!,bro you gonna die
@mclaren720
@mclaren720 5 ай бұрын
I will join you my brother.
@turtlebeast8812
@turtlebeast8812 5 ай бұрын
​@@mclaren720I will also join. let's get strong and smart together bros 💪💪💪
@mlfelonzo9156
@mlfelonzo9156 5 ай бұрын
Do my pushup bruh make sure
@td3de176
@td3de176 4 ай бұрын
You owe 305 pushups bro
@JoseLucasd
@JoseLucasd Ай бұрын
Nah, ill stay with C.
@user-vo2tu9hc7z
@user-vo2tu9hc7z 29 күн бұрын
why?
@user-vo2tu9hc7z
@user-vo2tu9hc7z 29 күн бұрын
Python is AI bro come on in
@JoseLucasd
@JoseLucasd 29 күн бұрын
@@user-vo2tu9hc7z python is heavy af. It takes like, 40s to run a encryption, and even a compiler like numba or cpython doesnt helps that much, bc python is natively slow. And also, its just too "washed out". Most of python libs like that used for ia or smth is written in c or c++. Thats the reason i dont like it. If it works for u, just use, bc u need to solve problems. And now machines r super fast unlike mine.
@TonyTony-dl9xr
@TonyTony-dl9xr 3 ай бұрын
Nothing new All time same 😂😂.But we always watch.I got it that study in University and pay for the study waste time and money. When in the KZbin available free Tutorials and Bootcamps.But after graduated University your knowledge not enough get job in IT company. You go to KZbin improve your knowledge for get job. I think it is simple and true fact by my own opinion.
@hannukoistinen5329
@hannukoistinen5329 3 ай бұрын
Unbelievable crap!!!
@nureke-dp1nw
@nureke-dp1nw 5 ай бұрын
We support Harvard's former president who wasn't afraid to speak the truth!
@d.k.1545
@d.k.1545 5 ай бұрын
Please give me more context.
@Samsung-zg9ql
@Samsung-zg9ql 5 ай бұрын
Whole of Python in one lecture. What's the point of watching this
@davidbarnhouse4642
@davidbarnhouse4642 5 ай бұрын
This is an intro class. The point is to introduce you to the topic not make you a master.
@Samsung-zg9ql
@Samsung-zg9ql 5 ай бұрын
@@davidbarnhouse4642 rather than making 500 introductory videos of 500 different languages it would be a lot beneficial to make videos of a few topics explaining in detail.. Can't believe people suggest cs50 which is clearly a waste of time...
@CoreyHillesheim
@CoreyHillesheim 5 ай бұрын
This is just scratching the surface. The CS50P lectures are 16 hours long and only cover the basics.
@davidbarnhouse4642
@davidbarnhouse4642 5 ай бұрын
@@CoreyHillesheim yes, that's the point.
@belabansal3356
@belabansal3356 5 ай бұрын
@@CoreyHillesheimthey taught like till week 4 of that in this video tbh. I am on week 8 currently of python. But you don’t get the detail of cs50 p obviously. And here and there, there were hints of other weeks
@VeNoMoP_69
@VeNoMoP_69 4 ай бұрын
For every like I will write 10 lines of python code
@-es2bf
@-es2bf 5 ай бұрын
They teach you this in high school in europe. lol cant imagine people let their rich parents pay for this basic stuff. total rip off.
@kejtos5
@kejtos5 5 ай бұрын
Ignoring the fact that each country in Europe has their own education system, I am pretty sure vast majority of people has not done any programming at high school and any programming at uni, let alone python.
@-es2bf
@-es2bf 5 ай бұрын
@@kejtos5 Most of the people I went to uni with already knew how to code. They wrote their own Java apps in high school. This course is a joke to be honest. How come americans dont feel ripped off, when they go into a lifetime debt to learn the equuvalent of a european high school
@kejtos5
@kejtos5 5 ай бұрын
​ @-es2bf Again, regardless of the quality of US unis (or lack thereof), there is no 'european high school' as every country has their own learning curriculum. The few CS-ish oriented high schools might teach something like Java (or C/C++), but I am almost 100% positive it is not the norm for high schools at most places. And also, universities don't tend to assume any knowledge and starts from the absolute beginning anyway.
@d.k.1545
@d.k.1545 5 ай бұрын
yeah...not everywhere in Europe bud. Sounds like you went to a school that thought itd be good to teach python, which I hope you enjoyed and helped you in this course.
@staying_substantially
@staying_substantially 4 ай бұрын
Bro it is one lesson, I doubt your high school in europe taught all that in one day
@shanksshaki
@shanksshaki 3 ай бұрын
ḍamn that teacher so fast speaking :O , i dont heard , that why im disble person ,reading subtitles only
@dazai826
@dazai826 3 ай бұрын
2:08:11 woww.... first time i got rickrolled without realising it at all.... kzbin.info/www/bejne/rqepi52larWafZI link of qr code.
@arungjose1849
@arungjose1849 2 ай бұрын
Now I can tell my friends that David rickrolled me 🥲😂
@karimashraf-mb5wb
@karimashraf-mb5wb 5 ай бұрын
🔥iam trapped in this course but love it 🤍🖤
CS50x 2024 - Lecture 7 - SQL
2:14:05
CS50
Рет қаралды 377 М.
CS50x 2024 - Artificial Intelligence
55:57
CS50
Рет қаралды 119 М.
버블티로 체감되는 요즘 물가
00:16
진영민yeongmin
Рет қаралды 39 МЛН
WHO DO I LOVE MOST?
00:22
dednahype
Рет қаралды 18 МЛН
Always be more smart #shorts
00:32
Jin and Hattie
Рет қаралды 24 МЛН
5 Good Python Habits
17:35
Indently
Рет қаралды 388 М.
Computer Scientist Answers Computer Questions From Twitter
14:27
The Two Types of Mathematics
9:29
Aaron Welson
Рет қаралды 43 М.
CS50x 2024 - Lecture 5 - Data Structures
2:02:49
CS50
Рет қаралды 243 М.
God-Tier Developer Roadmap
16:42
Fireship
Рет қаралды 6 МЛН
Why Most Self-Taught Developers Never Land The Job
7:28
Travis Media
Рет қаралды 150 М.
COMPUTER SCIENCE explained in 17 Minutes
16:49
Wacky Science
Рет қаралды 569 М.
Mastery: How to Learn Anything Fast | Nishant Kasibhatla
19:10
Ideas & Inspiration
Рет қаралды 14 МЛН
버블티로 체감되는 요즘 물가
00:16
진영민yeongmin
Рет қаралды 39 МЛН