Java: Loops and Iteration Question Why do cart totals often need a loop? (Click to reveal answer) Answer Because the same calculation must run across each cart line. A cart may have many items, and subtotal logic repeats per line. Loops are the basic tool for applying one calculation across a changing set of values. Additional NotesWhy do cart totals often need a loop? Track: Java Topic: Core Java Focus: Loops and Iteration Topics: Core Java Java Loops and Iteration