Effective Haskell: example uses "name" when "person" might be better (page 87)

The partyBudget’ example uses “name” as an argument to the lambda function used by filter. It also uses “filteredNames” to describe the resulting list.

Since these values are (name, cost) pairs, I think calling them names is confusing. I think it would be better to use “person” and “filteredPeople” or “guest” and “filteredGuests”.

1 Like

that’s a great point, I’ll rename it in the next batch of updates!

1 Like