Dictionaries in Python (Overview) - Data Types in Python - Python Tutorial for Beginners

preview_player
Показать описание
🎓 Welcome back to Digital Academy, the Complete Python Development Tutorial for Beginners, which will help you Learn Python from A to Z!

🖥️ Dictionaries in Python - Data Types in Python

Dictionary in Python is an unordered and indexed collection of values, used to store data. Unlike any other Data Types in Python that holds only single value as an element, dictionary holds key:value pair. Key-value is provided in the dictionary to make it more optimized, for retrieving data. It is generally used when you have a huge amount of data, since you must know the key, to retrieve the value - but not the other way around!

In Python, a Dictionary can be created by placing a sequence of elements within curly braces. Values in a dictionary can be of any data type and can even be duplicated, whereas keys cannot be repeated. And each key-value pair is separated by a colon, whereas each entry is separated by a comma.

my_dictionary = {1: 'value', 'key': 2}

Dictionary can also be created by the built-in function dict().

my_dictionary = dict()

Note: Dictionary keys are case sensitive. Same name but different cases of Key will be treated distinctly.

Let's play this video, stick around and watch until the end of this video! 👍🏻

- Digital Academy™ 🎓

***

☞ WATCH NEXT:

#Python #Tutorial #Beginners #Shorts

***

♡ Thanks for watching and supporting ♡
Please Subscribe. Hit the notification bell.
Like, Comment and Share.

***

♡ FOLLOW US ♡

♡ SUPPORT US ♡

***
Рекомендации по теме
Комментарии
Автор

When do you use Dictionary in Python? 🤔

DigitalAcademyOnline
Автор

Bonjour mon cher professeur, merci pour cette nouvelle vidéo très instructive :-)

PassionsByCath
visit shbcf.ru