Why? You’re removing the dependency and you’re also making your method more flexible giving the caller the ability to pass any kind of collection which implements that interface?
Why? You’re removing the dependency and you’re also making your method more flexible giving the caller the ability to pass any kind of collection which implements that interface.