Let’s check out some exercises that will help you understand structured data types in Python better, also usually referred to as composite data types as well.
list() is a function that creates an empty list. You don’t need to put anything inside list() function to achieve this. The same thing can be achieved by typing brackets: []
dictionary format is {} with keys and values in it. This is usually referred as a key-value pair as well. Each key will have a colon after it which is followed by the value of the key.
Thank you for visiting our website! We use essential cookies to help us understand and enhance user experience. By clicking “Accept”, you consent to the use of ALL the cookies.