Unit 3 Task 9: Merge two stock shelves

Learn to code with step-by-step lessons. A place for students to work through programming fundamentals and build skills.

Unit 3 Task 9 - Merge two stock shelves

← Unit 3 tasks - Solution


Shelf A and shelf B each have the same number of integer counts (e.g. three products). They are stored as two lists in your code, same length.

Create a third list where each entry is A[i] + B[i] for each index.

Print all three lists.

Skills: range(len(list)), parallel lists.