Skip to main content

Checkpoint: diagnose and repair

Challenge on lesson: Checkpoint: two bugs, one repair

CHALLENGE
Difficulty: advanced+25 XP

No class label. The method should remove every occurrence of target from an ArrayList<String>, preserving order, and return how many were removed. It returns wrong counts AND leaves some targets in the list. Classify, repair, verify.

Back to lesson: Checkpoint: two bugs, one repair