Dictionary in Python | Working with Dictionary | Add and Update Values in Dictionary | Loop over it

Опубликовано: 27 Октябрь 2024
на канале: Aditya Aurange
371
14

In this video we will discuss about Dictionary in Python.
Dictionary is a Mutable Object
Dictionary is a Mapping (Key : Value)
Dictionary is a Collection of key & value pair
Dictionary key are immutable & unique
Dictionary value can be anything, it can store any type of value
Dictionary elements are ordered, changeable & allows duplicate in value only
{} (Curly Brackets) are used in Dictionary
Eg. d = {1:'Ford' , 2:'Ferrari' , 3:'Pagani' , 4:'Maruti'}

We will also learn :-
How to loop over a Dictionary
How to Add an element (key value pair) in Dictionary
How to update value of a key in Dictionary