Nadeesha Cabral

74%
Flag icon
Of course, selectors need not be boolean. They can be enums, integers, or any other type of argument that is used to select the behavior of the function. In general it is better to have many functions than to pass some code into a function to select the behavior.
Nadeesha Cabral
On selector arguments
Clean Code: A Handbook of Agile Software Craftsmanship (Robert C. Martin Series)
Rate this book
Clear rating
Open Preview