Design

From FRC11 - Mentor Wiki
Revision as of 18:46, 30 October 2018 by Dsteinmark (talk | contribs) (Created page with "There are lots of ways to design software, of which we just give an overview of some of the more prominent and readily available techniques. === Flow Charts === Flow charts...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

There are lots of ways to design software, of which we just give an overview of some of the more prominent and readily available techniques.

Flow Charts

Flow charts are a good way to get started, though once you have a good feel for coding, other techniques often work better.

An example flow chart to fix a lamp

Flow charts consists of actions, states, decisions, and paths. Boxes can represent items to perform or states of items in the system. Diamonds represent decisions to make.

To design using flow charting, you have to think sequentially, and in terms of how control is determined - in particular, what decisions are to be made and on what basis.

Why Flow Charts can be good Flow charts can be useful even to the experienced programmer for smaller items and when trying to get a good feel for the sequence of actions and decisions that need to be made.

Why using Flow Charts can be bad

  • Flow charts have a tendency towards producing spaghetti code
  • Don't represent loops well
  • Don't represent objects well
  • Difficult to use decomposition
  • Unwieldy for large or complex items
  • Easier to design in pseudo code or using other techniques

Data Flow Diagrams

Decomposition

Pseudocode

Functional Specification

Object Oriented Design