| Next | Program
Repair Shop ![]() |
179 |
for my $x (0..2) {
for my $y (0..2) {
# do something
}
}
This occurs at least five times in the program
We should build a function to perform it
The function must fill in the #do something part
Our function will take a piece of code as its argument!
This is called a Higher-Order Function
| Next | ![]() |
Copyright © 2002 M. J. Dominus |