About Dictionaries

7 important questions on About Dictionaries

What is a dictionary?

It is a sort of list, but it stores pairs of items.

it looks like this internally:
1--> uno
2--> dos
3--> tres

What kind of brackets does a dictionary have?

A dictionary has akollades {} as brackets.

What is the difference between a list and a dictionary?

In a list order does matter, in a dictionary order doesn't matter.
  • Higher grades + faster learning
  • Never study anything twice
  • 100% sure, 100% understanding
Discover Study Smart

What functions can you use to find the keys and values in a dictionary?

.keys()
.values()

What function is used to add an element to a dictionary?

The .update()  function.

Is there another way possible to update a dictionary?

With the use of indexing, a dictionary can be updated(just like lists)

dict[1] = één

What is true about dictionaries?

- Lists are ordered, dictionaries aren't
- Lists contain elements, dictionaries contain pairs
- Lists are created with[], dictionaries are created with {}.

The question on the page originate from the summary of the following study material:

  • A unique study and practice tool
  • Never study anything twice again
  • Get the grades you hope for
  • 100% sure, 100% understanding
Remember faster, study better. Scientifically proven.
Trustpilot Logo