Dale - Computer Science Illuminated 177

# Dale - Computer Science Illuminated 177 - Put pot on the...

This preview shows page 1. Sign up to view the full content.

150 Chapter 6 Problem Solving and Algorithm Design To be an algorithm, the steps must solve a problem. In this case the problem is preparing a Hollandaise sauce, a wonderful mayonnaise-type sauce used on steak or for Eggs Benedict. Are the directions in a step-by- step fashion that someone can follow? Is there a finite amount of data— ingredients, in this case? Can it be made in a finite amount of time? Provided that the stove is working, the butter will eventually bubble. So we can answer yes to all three questions. This is definitely an algorithm. Of course, it is easier to follow an algorithm than it is to devise one. Let’s reorganize this recipe and present it in the algorithm format we used previously. Put butter in a pot Turn on burner
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Put pot on the burner While (NOT bubbling) Leave pot on the burner Put other ingredients in the blender Turn on blender While (more butter) Pour butter into blender in slow stream Turn off blender Never-Fail Blender Hollandaise Heat butter until bubbling. Combine all other ingredients in blender. With blender turned on, pour butter into yolk mixture in slow stream until all is added. Turn blender off. Keeps well in refrigerator for several days. When reheating, heat over hot, not boiling, water in double boiler. Makes about 1-1/4 cups sauce. 1 cup butter 4 egg yolks 1/4 teaspoon salt 1/4 teaspoon sugar 1/4 teaspoon Tabasco 1/4 teaspoon dry mustard 2 tablespoons lemon juice Figure 6.4 A recipe for Hollandaise sauce...
View Full Document

## This note was uploaded on 01/13/2011 for the course CSE 1550 taught by Professor Marianakant during the Fall '10 term at York University.

Ask a homework question - tutors are online