9
Unusual Control Structures and General Control Issues A Presentation by CJ Castellani as told in an American accent

Unusual Control Structures and General Control Issues A Presentation by CJ Castellani as told in an American accent

Embed Size (px)

Citation preview

Page 1: Unusual Control Structures and General Control Issues A Presentation by CJ Castellani as told in an American accent

Unusual Control Structures and General Control Issues

A Presentation by CJ Castellani as told in an

American accent

Page 2: Unusual Control Structures and General Control Issues A Presentation by CJ Castellani as told in an American accent

Returns

• Multiple returns can enhance a routine’s readability and maintainability, and they help prevent deeply nested logic.

• They should still be used carefully

Page 3: Unusual Control Structures and General Control Issues A Presentation by CJ Castellani as told in an American accent

Recursion

• Recursion provides elegant solutions to a small set of problems

• Also use carefully

Page 4: Unusual Control Structures and General Control Issues A Presentation by CJ Castellani as told in an American accent

GOTOs

• In a few cases gotos are the best way to write code that is understandable and maintainable

• But that is rare• They should be used as a last

resort

Page 5: Unusual Control Structures and General Control Issues A Presentation by CJ Castellani as told in an American accent

Boolean Expressions

• Simple and readable boolean expressions

• Improves quality of code

Page 6: Unusual Control Structures and General Control Issues A Presentation by CJ Castellani as told in an American accent

Nesting

• Deep nesting can make things overly complicated

• It is easily avoidable

Page 7: Unusual Control Structures and General Control Issues A Presentation by CJ Castellani as told in an American accent

Structure

• Simplifying your programming is still relevant

• Any program can be built with a combination of good structured sequences and iterations

Page 8: Unusual Control Structures and General Control Issues A Presentation by CJ Castellani as told in an American accent

Complexity

• Minimize it to write high quality code

Page 9: Unusual Control Structures and General Control Issues A Presentation by CJ Castellani as told in an American accent

More Humor