The Sierpinski gasket
- Determine how small the square is. If it's small enough to be a base case, then just fill in the square. You get to pick how small "small enough" is.
- Otherwise, divide the square into upper left, upper right, lower right, and lower left squares. Recursively "solve" three subproblems: 1. Draw a Sierpinski gasket in the upper left square. 2. Draw a Sierpinski gasket in the upper right square. 3. Draw a Sierpinski gasket in the lower right square.You need to make not just one, but three recursive calls. That is why we consider drawing a Sierpinski gasket to exhibit multiple recursion.