LearnFrenzy
Sign in Take a free test

Tuples · Tuples MCQ · Question 11

The type of a starred target Answer, explanation & discussion

  • MCQ
  • Medium
  • 0 comments
  • Answer explained
  • Moderated community
Question 11 Back to Exercise

After first, *rest = (1, 2, 3), what is rest?

  • A (2, 3) – a tuple
  • B 2
  • C [2, 3] – a list Correct
  • D [1, 2, 3]
Correct Answer: Option C

A starred name always collects into a list, whatever was unpacked.

Discussion & Comments 0

Share your method, a shortcut, or ask about a step you didn't follow.

No comments yet. Be the first to share your solution!

Post your comment

Comments appear after a quick review by our team.

Search LearnFrenzy

Esc

Quick links