Procedure

Reusing code

DRY

DRY stands for Don't Repeat Yourself. One of the Big Ideas of programming.

Big Idea

Don't repeat yourself

Write similar code once. Put it in a Sub. Use params to tell the Sub what to do differently each time the Sub is called.

So far, each of the subs has been called just once per program. Let's do something different.

Retaxing

Remember that strange tax return program? The worksheet:

Tax return

Let's add input validation.