The author recommends defining major data structures during requirements analysis and architecture phase.
The author then provides a data literacy test to identify what expertise the reader posses in understanding data structures. He also recommends reading some books if the reader is not an expert in data structures.
The author then enlists reasons to create own data types:
The author then provides a data literacy test to identify what expertise the reader posses in understanding data structures. He also recommends reading some books if the reader is not an expert in data structures.
The author then enlists reasons to create own data types:
- Make modifications easier in future
- Avoid excessive information distribution
- Increase Reliability
- Compensate for language weaknesses
- Create types with problem domain names
- Do not use predefined types (like int, float in C++) directly in the code except in type definitions
- Never redefine predefined types since it can create confusion in the mind of reader
- Define substitute types for portability
- Create types using other created types
- Use a template for variable declaration
- Turn of implicit declarations
- Use naming conventions
- A variable is never initialized
- A variable's value is outdated
- Only a part of the variable is assigned a value
- Check input parameters for validity
- Initialize each variable close to where it is used
- Check the need for reinitialization
- Initialize named constants once, initialize variables with executable code
- Initialize each variable as it's declared
- Use compiler setting to initialize all variables
- Use compiler warnings for uninitialized variables
- Use a memory access checker to check for bad pointers
- Initialize working memory at the beginning of the program