HP 3000 Manuals

How Do Programs Do What They Do? [ Understanding Your System ] MPE/iX 5.0 Documentation


Understanding Your System

How Do Programs Do What They Do? 

If you have ever followed a recipe to cook a meal, or assembled something
using printed instructions, you have gone step by step through a sequence
of instructions, much the way a computer goes step by step through a
program.

Mama's Nice, Simple Tomato Sauce 

Ingredients 

   *   fresh tomatoes, 3 or 4, cut up (peeled and seeded, if you wish).
       Save the juice.
   *   olive oil, one tablespoon
   *   garlic, one clove, minced
   *   onion, one-half, diced
   *   fresh basil, two or three leaves
   *   salt and pepper to taste

Directions 

   1.  Warm the oil in a heavy pan or skillet.
   2.  Add garlic and onion, cook gently until onions are translucent.
   3.  Add tomatoes, tomato juice, and basil.
   4.  Add salt and pepper to your liking.
   5.  Simmer and allow the liquid to reduce.
   6.  Taste and correct the seasonings.
   7.  Serve over hot, cooked pasta.

Everything you need to know in order to prepare this sauce is given in
this recipe:  what you need to buy, what you need to do.  Computer
programs do for computers what recipes do for cooks--organize information
and provide instructions for carrying out tasks.

Sometimes these instructions are no more complex than following a
sequence of unchanging steps.  More complicated methods require analysis
and decision.

       "If the cost of production exceeds revenues by 2 percent in any
       three consecutive months...."

       "While lemons are on sale, buy lemons and make pies...."

       "Buy lemons and make pies until the price of lemons has increased
       by 6 percent..."



MPE/iX 5.0 Documentation