正在加载图片...
Contents 5.8 Graphics Module Reference............... 151 5.8.1 GraphWin Objects 151 5.8.2 Graphics Objects 152 5.8.3 Entry Objects.... 155 5.8.4 Displaying Images 155 5.8.5 Generating Colors 156 5.9 Chapter Summary… 156 5.10 Exercises......… 157 Chapter 6 Defining Functions 165 6.1 The Function of Functions 165 6.2 Functions,Informally 167 6.3 Future Value with a Function. 171 6.4 Functions and Parameters:The Details.............. 173 6.5 Getting Results from a Function.. 177 6.5.1 Functions That Return Values. 177 6.5.2 Functions that Modify Parameters........ 181 6.6 Functions and Program Structure. 187 6.7 Chapter Summary.… 191 6.8 Exercises... “444+44+ 191 Chapter 7 Decision Structures 199 7.1 Simple Decisions.… 199 7.1.1 Example:Temperature Warnings... 200 7.1.2 Forming Simple Conditions................ 202 7.1.3 Example:Conditional Program Execution 204 7.2 Tw0-Way Decisic0nS… 206 7.3 Multi--Way Decisions… 210 7.4 Exception Handling......... 213 7.5 Study in Design:Max of Three............... 217 7.5.1 Strategy 1:Compare Each to All.... 218 7.5.2 Strategy 2:Decision Tree........... 220 7.5.3 Strategy 3:Sequential Processing 221 7.5.4 Strategy 4:Use Python........ 223 7.5.5 Some Lessons............ 44444 224 7.6 Chapter Summary… 225 7.7 Exercises..... 225 Chapter 8 Loop Structures and Booleans 233 8.1 For Loops:A Quick Review............... 233 8.2 Indefinite Loops............ 235 8.3 Common Loop Patterns 237 8.3.1 Interactive Loops 237 8.3.2 Sentinel Loops… 239 8.3.3 File Loops..... 242Contents 5.8 Graphics Module Reference 151 5.8.1 GraphWin Objects 151 5.8.2 Graphics Objects 152 5.8.3 Entry Objects 155 5.8.4 Displaying Images 155 5.8.5 Generating Colors 156 5.9 Chapter Summary 156 5.10 Exercises 157 Chapter 6 Defining Functions 165 6.1 The Function of Functions 165 6.2 Functions, Informally 167 6.3 Future Value with a Function 171 6.4 Functions and Parameters: The Details 173 6.5 Getting Results from a Function 177 6.5.1 Functions That Return Values 177 6.5.2 Functions that Modify Parameters 181 6.6 Functions and Program Structure 187 6.7 Chapter Summary 191 6.8 Exercises 191 Chapter 7 Decision Structures 199 7.1 Simple Decisions 199 7.1.1 Example: Temperature Warnings 200 7.1.2 Forming Simple Conditions 202 7.1.3 Example: Conditional Program Execution 204 7.2 Two-Way Decisions 206 7.3 Multi-Way Decisions 210 7.4 Exception Handling 213 7.5 Study in Design: Max of Three 217 7.5.1 Strategy 1: Compare Each to All 218 7.5.2 Strategy 2: Decision Tree 220 7.5.3 Strategy 3: Sequential Processing 221 7.5.4 Strategy 4: Use Python 223 7.5.5 Some Lessons 224 7.6 Chapter Summary 225 7.7 Exercises 225 Chapter 8 Loop Structures and Booleans 233 8.1 For Loops: A Quick Review 233 8.2 Indefinite Loops 235 8.3 Common Loop Patterns 237 8.3.1 Interactive Loops 237 8.3.2 Sentinel Loops 239 8.3.3 File Loops 242
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有