Integer division and Math.mod
Use Integer for whole counts.
Your task
Compute full packs and leftovers twice: once for 17 seats, then again after seatsSold = 20;.
Integer seatsSold = 17;
Integer packSize = 5;
// Case A: 17 seats
// Case B: 20 seats
seatsSold = 20;Requirements
Case A packs: 3should be printedCase A leftover: 2should be printedCase B packs: 4should be printedCase B leftover: 0should be printed- Packs should be computed by dividing by
packSize - Leftover should be computed with
Math.modon the variables