Q. =[x+y for x, y in zip(l1, l2)] l3

  • (A) error
  • (B) 0
  • (C) [-20, -60, -80]
  • (D) [0, 0, 0]
πŸ’¬ Discuss
βœ… Correct Answer: (D) [0, 0, 0]
Explanation: the code shown above returns x+y, for x belonging to the list l1 and y belonging to the list l2. that is, l3=[10-10, 20-20, 30-20], which is, [0, 0, 0].

Explanation by: Mr. Dubey
the code shown above returns x+y, for x belonging to the list l1 and y belonging to the list l2. that is, l3=[10-10, 20-20, 30-20], which is, [0, 0, 0].

πŸ’¬ Discussion

πŸ“Š Question Analytics

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