Download presentation
Presentation is loading. Please wait.
Published byAlexander Dennis Modified over 9 years ago
1
Kruse/Ryba Ch011 Object Oriented Data Structures Programming Principles Introduction Programming Style Coding, Testing, Further Refinement Program Maintenance Conclusions and Preview
2
Kruse/Ryba ch012 Introduction Problem Specification Program Design Choice of Data Structures Analysis of Algorithms Testing and Verification Program Correctness Maintenance C++
3
Kruse/Ryba ch013 Names (identifiers) Meaningful – CS Department Standard Simple when local Use common prefixes and suffixes Avoid intentional misspellings Avoid cute Avoid similar spellings Beware of confusing letters – o0, il, 1l, etc. Accounts_payable size loopIndex x
4
Kruse/Ryba ch014 Documentation (Comments) Prologues for functions Explain variables Introduce significant sections Indicate ends of significant sections - //End main( ) Avoid redundant & verbose comments Explain tricky code – Better still avoid it! Documentation explains what not how Document Modifications /*…*/, //, /// Visual Studio /*************** * ****************/
5
Kruse/Ryba ch015 Format Spaces, blank lines, indentation Prettyprinting Consistency –Like writing an essay
6
Kruse/Ryba ch016 Refinement (Refactoring) Subdivision Top-down refinement Specifications Plain and Simple (KISS) Parameters –Input –Output –InOut Variables –Local –Global –Magic Numbers
7
Kruse/Ryba ch017 Coding, Testing, Further Refactoring Stubs – Function / Class Drivers – main call your program function to get started Program Tracing –Structured walkthroughs – Single Step –Trace tools – Break Points –Snapshots - cout –Scaffolding –Static analyzer
8
Kruse/Ryba ch018 Testing Unit Tests Black-Box –Easy values –Typical, realistic values –Extreme values –Illegal values Glass-Box – White Box Ticking-Box
9
Kruse/Ryba ch019 Program Maintenance Solution within specifications? Correct under all conditions? Interface? Logically and clearly written? Well documented? Efficient use of time and space? Reasonable?
10
Kruse/Ryba ch0110 Chapter 1 Fades Away
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.