CBSE Class 11 Informatics Practices Question 1 of 66

Dictionary — Question 1

Back to all questions
1
Question

Question 1

Assertion (A): Dictionary is a collection of key-value pairs.

Reasoning (R): Each key in a dictionary maps to a corresponding value. Keys are unique and act as the index.

  1. Both A and R are true and R is the correct explanation of A.
  2. Both A and R are true but R is not the correct explanation of A.
  3. A is true but R is false.
  4. A is false but R is true.
Answer

Both A and R are true and R is the correct explanation of A.

Explanation
A dictionary is a collection of key-value pairs, where each key is unique and maps to a corresponding value. The keys act as the index, allowing to access and manipulate the values associated with them.