nature-of-code / noc-examples-processing

Repository for example code from The Nature of Code book
MIT License
2.56k stars 951 forks source link

Update Liquid.pde #31

Closed overbk closed 11 years ago

overbk commented 11 years ago

The 'contains' function can be simplified so that it is better readable (at least, in my opinion). If my suggestion is accepted, the related code snippet in Chapter 2 of the book and the file liquid.pde in the folder NOC_2_5_fluidresistance_sequence must be similarly updated as well.

(Thanks for the great book.)

shiffman commented 11 years ago

This is a really good suggestion. I find that with beginners having the explicit "return true" and "return false" statements help with understanding. Then again this example is really for "total" beginners. I'll pull it in and see how it goes!