Key Points

 < Free Open Study > 

  • Structures can help make programs less complicated, easier to understand, and easier to maintain.

  • Whenever you consider using a structure, consider whether a class would work better.

  • Pointers are error-prone. Protect yourself by using access routines or classes and defensive-programming practices.

  • Avoid global variables, not just because they're dangerous, but because you can replace them with something better.

  • If you can't avoid global variables, work with them through access routines. Access routines give you everything that global variables give you, and more.

 < Free Open Study > 


Code Complete
Code Complete: A Practical Handbook of Software Construction, Second Edition
ISBN: 0735619670
EAN: 2147483647
Year: 2003
Pages: 334

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net