Good instinct, and here's the piece underneath it: a list keeps insertion order but checking membership scans every element, so on a big collection it gets slow. A set trades order for near-instant lookups. Notice what you're optimizing for, and the right structure usually picks itself.
