next up previous contents
Next: Header Files and General Up: Recongnising Common Bugs When Previous: Silent but Deadly   Contents

Monsters from the If

`If statements' are nearly always the cause of most development bugs. There is a multitude of ways they can be incorrectly used. In general you should attempt to use them with care using `if .. then .. else ' constructs helps.

Try to minimise the total number, every new statement generates a new branch of execution possibilities increasing the overall number of ways that the program can execute by another factor of two (LESS PATHS = LESS TESTING).

Algorithms should never be written so that they are sensitive to arbitrary thresholds, they should be based on `soft' statistical methods if possible. This generaly follows directly if an algorithm is designed using a statistical methodology (see Tina memo 2002-005) which takes due account of accuracy of data.

Here are a few cases of potential error to look out for;


next up previous contents
Next: Header Files and General Up: Recongnising Common Bugs When Previous: Silent but Deadly   Contents
root 2017-09-20