Professional Documents
Culture Documents
Functional Rules
A lot of the power of functional programming comes from following some simple rules and
best practices. Let's go over those so we can know what to do and what to avoid.
Functional programming is a popular approach in a lot of languages and is even the main
approach in some. If you find you like functional programming, check out the languages
Haskell and Scala.
The rules
global and nonlocal let you work with variables from a higher scope. You should have
global
and
nonlocal
docs
Functional Workhorses
Now that we know the rules of functional programming, let's meet the tools we'll use the
most. We'll also see how each of these utilities helps us stick to the rules of functional
programming better.