Skip to main content
🔒 Preview mode. The first 15 Foundations lessons are free; this one is Pro. Start a 7-day trial to unlock the editor, AI hints and the rest of the curriculum. Card required, cancel any time in Dashboard.Start 7-day trial →
← CoursesPython FoundationsModule 4 · Object-oriented programmingQuiz: What is the error for missing key?quiz58 / 174
+60 XP
Task
📝 **Question:** What error will `d["x"]` cause if the dictionary `d` does not contain the key `"x"`? 📋 Choose from options. 💡 **Hint:** for lists there is a missing index → ​​`IndexError`. For the dictionary - another error with a similar word.
🎯 Quiz

Question

📝 **Question:** What error will `d["x"]` cause if the dictionary `d` does not contain the key `"x"`? 📋 Choose from options. 💡 **Hint:** for lists there is a missing index → ​​`IndexError`. For the dictionary - another error with a similar word.

💬 Discussion

Be the first to ask a question or share a tip.
Sign in to join the discussion. Reading is free.
Loading discussion…