Game development
Separate collision detection from response
Detection asks whether shapes overlap; response decides what that means. Keeping them separate lets a projectile, a collectible and a wall share geometry while producing different results.
Collect collision results before removing objects from arrays. This avoids skipping objects and makes simultaneous events easier to reason about.
Continue the study
Work through a small code example, make one deliberate change and record the effect. The reading links below connect this exercise with animation, input and retro game design.