CS50x 2024 - Lecture 5 - Data Structures

  Рет қаралды 202,872

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 - Stacks and Queues
00:09:53 - Jack Learns the Facts
00:12:01 - Resizing Arrays
00:30:33 - Linked Lists
01:16:09 - Trees
01:30:34 - Dictionaries
01:34:26 - Hashing and Hash Tables
01:52:36 - Tries
***
HOW TO SUBSCRIBE
kzfaq.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
KZfaq: / 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

Пікірлер: 97
@oskartrinh6001
@oskartrinh6001 27 күн бұрын
Just finished watching lecture 5. Now it's time to watch it again like 3 more times. :D
@sultanghani7356
@sultanghani7356 16 күн бұрын
This man is doing more work than the hardwares.
@pavan7335
@pavan7335 2 ай бұрын
Intro music is a banger!!! Whoever composed it, hatsoff!
@parthdeshwal4419
@parthdeshwal4419 Ай бұрын
indeed
@shinthantkaung
@shinthantkaung 22 күн бұрын
I luv it
@wsollers1
@wsollers1 2 ай бұрын
As a seasoned developer, I use these videos to augment my son's curriculum. This is invaluable knowledge laid out in a clear and compelling way.
@Rodrigo_Pimenta
@Rodrigo_Pimenta 27 күн бұрын
Can you elaborate? Why is it valuable to say on your curriculum that you whached the CS50 online course?
@ousseynoukone
@ousseynoukone 15 күн бұрын
​@@Rodrigo_Pimenta You'll receive a certificate at the end... A certificate that carries significant weight. CS50 is one of the top online courses for an introduction to CS.
@anshuraj4277
@anshuraj4277 9 күн бұрын
Is there any Python DSA course U can recommend
@Aman-fz1ew
@Aman-fz1ew 3 ай бұрын
Top quality demonstration .
@Shawky.
@Shawky. 4 ай бұрын
Happy New Year and all the best for 2024 ! Happy Coding 😃
@sefonefinpsefnpefn4191
@sefonefinpsefnpefn4191 3 ай бұрын
finally finish this video! keep going guys!
@blessdarah1256
@blessdarah1256 3 ай бұрын
This was such a wondeful course. Well put and in very simple terms. If you already have a descent understanding of DSA and some C, it's going to be flawlessly easy to pull through the course.
@evachen4709
@evachen4709 3 ай бұрын
I've watched CS50 2023 to get started with some concepts of CS and now cmoe back to 2024 from time to time to see David explainging some specifiec concepts when I bump into them when solving problems. Really honored to have David, CS50 series and the team. Many thanks.
@omowomaroland1880
@omowomaroland1880 2 ай бұрын
Truly very simplified approach
@anasanas7842
@anasanas7842 4 ай бұрын
"I have no idea what im studying" lol
@sahil-anurag
@sahil-anurag 3 ай бұрын
yeah! i have noticed. lol😂😂
@abdullah.al.Jubouri
@abdullah.al.Jubouri 2 ай бұрын
شكرا ديفيد واخيرا خلصت الاسبوع الطويل هذا وبالتوفيق للجميع
@fest8177
@fest8177 4 ай бұрын
We’re back again with this hellish week 😂
@aftertwentea
@aftertwentea 4 ай бұрын
This is it, the stumbling stone of CS50🎉🎉🎉
@villagerdude2989
@villagerdude2989 2 ай бұрын
Fr 💀
@surferguy45
@surferguy45 2 ай бұрын
What exactly do you mean by “stumbling”
@misterguy
@misterguy 2 ай бұрын
@@villagerdude2989all I see is everyone loves these lectures
@lintz_lin
@lintz_lin 7 күн бұрын
@@surferguy45 Late answer here but I think it's because this is one of the hardest part of the CS50 course, if you get past this block then you'll be very likely to finish the whole course. Some people unfortunately give up at week 4 or week 5.
@surferguy45
@surferguy45 7 күн бұрын
@@lintz_lin oh okay, makes sense. I find it very interesting and refuse to give up until I finish, just turned in week 9 and about start final project once i get everything properly setup locally. Wishing the best of luck and good vibes to everybody else!
@fbiagent6081
@fbiagent6081 3 ай бұрын
Where was this when i needed it 😭
@johnmayfield7662
@johnmayfield7662 Ай бұрын
I loved the balloons explanation Mr. David
@DTALKS01
@DTALKS01 15 күн бұрын
Amazing explanation of hash table
@WizeChoice
@WizeChoice Ай бұрын
So Amazing 👉🏾✨✨✨
@cybrd230
@cybrd230 4 ай бұрын
It suddenly started making a lot more sense.
@thankyouthankyou1172
@thankyouthankyou1172 3 ай бұрын
I like how well the lecture was prepared: handing out cookies to demo FIFO
@user-gc9sp7bx5z
@user-gc9sp7bx5z 3 ай бұрын
Dave has done more than 90% of profs out there. respect.
@philippwiederkehr7262
@philippwiederkehr7262 28 күн бұрын
I liked the balloons demonstration!
@huropjohe2922
@huropjohe2922 3 күн бұрын
1:15:00, I think if node's number is equal, '=' can be add at line62 or line41.
@andoryu14
@andoryu14 Ай бұрын
I recall people saying week 3 or 4 were the hardest, but this week has really deflated my sails and I'm not even at the pset yet
@nanoalt8127
@nanoalt8127 26 күн бұрын
this one is giving me a headache trying to understand pointer arithmetic. I now see why people call C an archaic language if you're new
@surferguy45
@surferguy45 7 күн бұрын
Yall got this!! Just keep watching lectures and sessions and read the notes if needed.
@andoryu14
@andoryu14 15 сағат бұрын
Update: finally submitted the final week 5 problem more than a month later. Hardest week so far for me by a lot, but getting this far has taken me 9 months to do 5 weeks of problems. Don't give up!
@surferguy45
@surferguy45 15 сағат бұрын
@@andoryu14 Well done! Speller was certainly a tricky one, I’m not even sure if I’d be able to easily redo it if I were to try it again, but to be fair, a lot of these problem sets are really hard to FULLY digest within only a week, they’re mostly just things you get better at by repeating over time to get more comfortable with. Just a few more weeks to go! The stuff with Python is a breath of fresh air, I just got to the final project about a week ago, still haven’t made much progress with it if I’m being honest since everything is coming from scratch and I’m having trouble with planning out how I want everything to look and work, but I think you’ll like the next few weeks, especially the week with SQL, that was a fun problem set.
@vwhxss-390
@vwhxss-390 5 сағат бұрын
​@@andoryu14 Cool bro I just finished week 4, wish me luck
@DebopriyoBasu
@DebopriyoBasu 3 ай бұрын
Thank you for sharing this online. Time to fix my knowledge gaps.
@AudisioOficiaI
@AudisioOficiaI 3 ай бұрын
how are you verified???
@ProgrammerPenguin
@ProgrammerPenguin 28 күн бұрын
why are you verified?
@budiardjo6610
@budiardjo6610 2 ай бұрын
i am glad he is using c language
@efei_
@efei_ 4 ай бұрын
Nice
@born2fight77
@born2fight77 3 ай бұрын
hi, at the time line 27.57, do we need to free temp also,, line no 29-free(list); ,line no 30- list = tmp; here list has been assigned with tmp, line 31- as per my thoughts - free(tmp);
@ItsMidNightDev
@ItsMidNightDev Ай бұрын
I believe at that point 'list' now points to the memory that was allocated to 'tmp', as he set 'list = tmp' on line 30, so 'free(list)' on line 37 is basically free-ing the memory that was once allocated to tmp. I'm still learning this myself so if that's incorrect please correct me :)
@huropjohe2922
@huropjohe2922 3 күн бұрын
1:21:27 英文字幕裡的[INAUDIBLE],因該是mario,馬力歐,前幾堂課舉的例子。
@antonioskokiantonis7051
@antonioskokiantonis7051 4 ай бұрын
Ok, thank you C, we're moving to your modern child, Python!
@ProgrammerPenguin
@ProgrammerPenguin 28 күн бұрын
lmao!
@kuldeeppal7229
@kuldeeppal7229 12 күн бұрын
Today is my exam, wish me luck 🤞
@aasrp661
@aasrp661 Күн бұрын
Yes bro good good exams. 😎
@aidanthompson5053
@aidanthompson5053 3 ай бұрын
1:14:22
@AhamdMQ
@AhamdMQ 8 күн бұрын
what if we have more than one person with the same name when we're using Tries?
@Vhc706
@Vhc706 2 ай бұрын
Raise your hand if you choked up on linked lists 🤚
@80greaty
@80greaty 2 ай бұрын
He earned my respect when he pronounced valgrind "val grinned"
@IHateMondaysToo
@IHateMondaysToo 21 сағат бұрын
makes me think of norse mythology
@asrarlone8660
@asrarlone8660 21 күн бұрын
is it full dsa course
@wanderingfido
@wanderingfido 3 ай бұрын
8:02 It's misleading to use method names _push_ and _pop_ because those are the typical functions for an array. During which the more cpu-intensive operations of shrinking and expanding the physical size/length of an array is committed. The _get()_ and _put()_ methods more accurately imply that cells/elements within the queue are _overwritten_ or non-destructively _read_ as per index values updated within _head_ and _tail_ integer variables. While the size/length of the array remains fixed according to a _CAPACITY_ value.
@Nanagos
@Nanagos 4 ай бұрын
I didn't even notice until now, that David Malan is wearing the same thing all the time 😅
@shinthantkaung
@shinthantkaung 8 күн бұрын
@oteikwufrancis1108
@oteikwufrancis1108 4 ай бұрын
A simple question dear sir. It seems, once cursor->next is converted from NULL to n we loose the pointer to NULL. So how do we set the last element in this list to point at NULL? Me thinks the pointers if a node is created without assigning it a pointer, the pointer is implicitly set to NULL. Am I right?
@poggybitz513
@poggybitz513 3 ай бұрын
No. It could be set to garbage value. You need to explicitly set the pointer to NULL.
@oteikwufrancis1108
@oteikwufrancis1108 3 ай бұрын
Thank you sir @poggybitz513 . It seems that wasn't done in the code we were given.
@jerrypro9454
@jerrypro9454 Ай бұрын
57:50 Is it just me or atoi function was never introduced before in the lecture?
@paiksprod8358
@paiksprod8358 29 күн бұрын
Atoi was introduced in problem sets, probably in week 3 as i remember because i used it myself before week 5. In general problem sets requires sometimes more than just watching the lecture
@bikashtamang9756
@bikashtamang9756 15 күн бұрын
even tough he is explainging in such a goood way don't know why i am not able to understand it
@King_504
@King_504 8 күн бұрын
I think he's a tad bit too animated. gotta weed through his fluff to get to the actual message he's trying to convey
@aidanthompson5053
@aidanthompson5053 3 ай бұрын
1:37:25
@emilsjoblom273
@emilsjoblom273 2 ай бұрын
what do you mean?
@ProgrammerPenguin
@ProgrammerPenguin 28 күн бұрын
@@emilsjoblom273 comments appear top for the commentators so its prolly a note comment for later.
@IRONMAN-to7yl
@IRONMAN-to7yl 3 ай бұрын
38:06
@mohamedibrahim1836
@mohamedibrahim1836 3 ай бұрын
First of all great efforts and brilliant content! That said, I am always fascinated with how educators can make simple concepts sound like they are talking statistical mechanics or some sophisticated topic! I am not sure if the impact is to keep students alerted or the average students will be thinking ooh this is so sophisticated and result in anxiety! not sure! but what I am sure of is that these are pretty average logical informational topics like most of computer science subjects and they don't require all this excitation!
@phonixMAM
@phonixMAM 2 ай бұрын
they dont if youre chatgpt
@svengoerdes1705
@svengoerdes1705 Ай бұрын
Well in my opinion this excitement and playfull approach is one of the best ways to keep the students concentrated and interested. Excitement is not required but it makes the lecture so much more interesting. You could say the same thing about every subject in school. Compared to your knowledge almost everything is "average". However, it is not to the students! So please rethink your opinion and try to avoid calling information "average".
@MooseGoWoof
@MooseGoWoof 4 ай бұрын
Anyone else watching at 2 times speed?
@Aman-fz1ew
@Aman-fz1ew 3 ай бұрын
Nope
@bekay7663
@bekay7663 3 ай бұрын
I get distracted if not lol
@bekay7663
@bekay7663 3 ай бұрын
​@@Aman-fz1ewyep
@syedzainulabideen4455
@syedzainulabideen4455 4 ай бұрын
1like = 5pushups in 2024
@theXsun
@theXsun 6 күн бұрын
You say that on every lecture
@aliakseivasiukovich8244
@aliakseivasiukovich8244 Ай бұрын
How much money did Nintendo pay for the commercial? Almost every lesson mentions Nintendo characters. The course is great, though. Just my observation
@ProgrammerPenguin
@ProgrammerPenguin 28 күн бұрын
no, it's just an example to better connect with the students as said by professor David himself, he also uses characters like binky and oscar the grouch!
@DarkDevilVaqif
@DarkDevilVaqif Ай бұрын
why is he adopting and putting kids up for adoption
@user-ut4zh3pw7l
@user-ut4zh3pw7l 2 ай бұрын
overengineered sorry bs
@einfacherkerl3279
@einfacherkerl3279 3 ай бұрын
I don't know why he had so much drama instead of the actual knowledge. He spent good 35 minutes distributing cookies while barely discussing stack and queue. Time thoroughly wasted
@saqib7685
@saqib7685 5 күн бұрын
Because it doesn't make us feel bored.
@romievthedon
@romievthedon 3 ай бұрын
You never freed tmp, via free(tmp), 29:00. I want my cookies😂
@nitinkashyap2619
@nitinkashyap2619 2 ай бұрын
he mistakely free(list) again inside free(temp)
@cklai350
@cklai350 15 күн бұрын
list and tmp here are pointing at the same chunk of memory. Thus, you should not free it again.
@romievthedon
@romievthedon 15 күн бұрын
@@cklai350 Ahhhhh, okay. Thanks for the clarification😅 I still have yet to toy around with C. I've dabble with C++ for unreal engine but that's about it. I expect to use C officially when I start working with embedded systems in the next couple of weeks.
@aidanthompson5053
@aidanthompson5053 3 ай бұрын
36:57
@anasanas7842
@anasanas7842 4 ай бұрын
1:39:40 1:41:45 1:43:32
@charlesabju907
@charlesabju907 4 ай бұрын
I wonder what he actually said in the live class instead of Lakitu
@angiehidalgo5190
@angiehidalgo5190 2 ай бұрын
@@charlesabju907 I NEED ANSWERS
CS50x 2024 - Lecture 6 - Python
2:09:03
CS50
Рет қаралды 237 М.
CS50x 2024 - Lecture 7 - SQL
2:14:05
CS50
Рет қаралды 317 М.
skibidi toilet 73 (part 2)
04:15
DaFuq!?Boom!
Рет қаралды 32 МЛН
Glow Stick Secret 😱 #shorts
00:37
Mr DegrEE
Рет қаралды 126 МЛН
Harvard CS50’s Artificial Intelligence with Python - Full University Course
11:51:22
3 Types of Algorithms Every Programmer Needs to Know
13:12
ForrestKnight
Рет қаралды 423 М.
Computer Scientist Answers Computer Questions From Twitter
14:27
Faster than Rust and C++: the PERFECT hash table
33:52
strager
Рет қаралды 497 М.
Lecture 1: Introduction to CS and Programming Using Python
1:03:30
MIT OpenCourseWare
Рет қаралды 313 М.
DATA STRUCTURES you MUST know (as a Software Developer)
7:23
Aaron Jack
Рет қаралды 918 М.
CS50 Lecture by Mark Zuckerberg - 7 December 2005
1:05:35
CS50
Рет қаралды 8 МЛН
skibidi toilet 73 (part 2)
04:15
DaFuq!?Boom!
Рет қаралды 32 МЛН