Java · ArrayList and wrapper classes

Removing while you traverse

Clearing bad values out of a list is a loop that looks right, runs without an error, and can leave some of them behind.