previous | start | next

## From Pseudocode to Code

- Before starting to program, we need to have a plan.
- Any time you need something more than once, it's a good idea to turn that into a function..
- Rather than writing the entire function, begin by writing the comments.
- Example: Writing the function

  >     /**
  >        Turns a number into its English name.
  >        @param n a positive integer < 1,000,000
  >        @return the name of n (e.g. "two hundred seventy four"
  >     */
  >     string int_name(int n);

previous | start | next