Foreach is preferred over map when only side effects are desired.