Q. What does `enumerate()` do?

  • (A) Counts list items
  • (B) Returns index and item pairs
  • (C) Creates a list
  • (D) Sorts a list
πŸ’¬ Discuss
βœ… Correct Answer: (B) Returns index and item pairs
Explanation: `enumerate()` returns both index and value when looping over an iterable.
Explanation by: Mr. Dubey
`enumerate()` returns both index and value when looping over an iterable.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
64
Total Visits
πŸ“½οΈ
1 y ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
94%
Success Rate