Python Programming Tutorial - 41 - Min, Max, and Sorting Dictionaries

Python Programming Tutorial - 41 - Min, Max, and Sorting Dictionaries

thenewboston

9 лет назад

114,326 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

Afif Khaja
Afif Khaja - 25.10.2022 00:31

Great tutorial. Why do I have to call the zip function every time? I tried to save zip in a variable for reuse but Python throws an error: empty argument

Ответить
Sound of Silence
Sound of Silence - 25.01.2022 18:26

Bro, I liked your tutorials. But get something for your gas trouble.

Ответить
Crux3r
Crux3r - 03.01.2022 20:22

Dude i love how chill you are teaching some cool stuff. Cheers 🥂

Ответить
Drew
Drew - 29.08.2021 22:48

For anyone interested, you can sort in reverse order this way:
print(sorted(zip(stocks.keys(), stocks.values()), reverse=True))

Ответить
maw kuri
maw kuri - 14.07.2021 04:16

what if there are 2 equal values in the dictionary? how do you get those 2 items(keys, values) to print?

Ответить
Zdeněk Ratka
Zdeněk Ratka - 31.08.2020 20:02

"Amazon stock prices are actually pretty expensive around 306"
Me: looks it up
HOly shit 6000 is a bit more

Ответить
Marko Vasic
Marko Vasic - 20.04.2020 20:40

Thanks for the video burping buddy!

Ответить
Jay Bee
Jay Bee - 20.04.2020 16:40

5 years ago: Amazon is pretty 'expensive' trading around 305 dollars.

Today: Amazon is 2400 dollars and what was i doing 5 years ago 😢

Ответить
Alexandre Scimone
Alexandre Scimone - 23.03.2020 12:40

How to destroy a very interesting video, by burping and talking shit. A brilliant mind trapped in a 15 years old boy.

Ответить
Inanna Inai
Inanna Inai - 17.09.2019 15:49

The burping is really disgusting! Expacially if you have to rewind the video because you've missed somethin
The first time I thougt: "Ok, happens!"
The second time I thought: "Why isn't he cutting it out?"
Now I'm totaly disgusted when I hear it! So much that I don't want to continue this tutorial and I don't think I'll watch any of your tutorials again.


I'm sure thats not your intention, and its sad because you are quite good at teaching.

Ответить
Paul Morrey
Paul Morrey - 23.04.2019 22:23

Thanks Bucky

Ответить
Alexander Smirnoff
Alexander Smirnoff - 11.02.2019 22:45

STOP BURPING! PIGGIE

Ответить
Ipsita Majumder
Ipsita Majumder - 21.01.2019 08:33

Thanks for the videos . These are very useful. Just a request, please stop burping ,check your diet and exercise routine.

Ответить
fahim toufiqul islam
fahim toufiqul islam - 12.01.2019 21:15

i am not gettin 720p or 1080p in these videos.

Ответить
inspirational_talkings
inspirational_talkings - 18.06.2018 09:15

Sir, if zip function always gives priority to the first parameter inside the bracket then why to mention the 2nd parameter inside the bracket ????

Ответить
Guillermo Garcia
Guillermo Garcia - 22.04.2018 23:37

I´m a illustrator trying to learn Programmation... and I can´t stop asking: "How do you reverse the sort??, I mean, I want the high value first"

Ответить
Ahmed Elshayeb
Ahmed Elshayeb - 06.04.2018 16:52

i was following you but because of your brups , it will fuck off your vedios and channel

Ответить
Jack42
Jack42 - 13.03.2018 01:17

What's really strange, if i store the zipped list and call max after min, it gives the exception ValueError: max() arg is an empty sequence

zipped_list = zip(stocks.values(), stocks.keys())
print(min(zipped_list))
print(max(zipped_list))

Does min() actually clear the list? It doesn't make sense to me. If i call min two times the second call fails as well.

Ответить
Paweł Brysch
Paweł Brysch - 08.03.2018 21:20

Jest jeszcze drugi filmik na ten temat, ma nr 53
Natomiast 55 ma jakiś multiple sorting

Ответить