2.3 Producing Robust Programs Flashcards
Types of defensive design and explain them
Anticipate how users will misuse it and prevent it
Reduce errors in code
Well-maintain code
authentication
Input validation
Checking data meets certain criteria before it is inputted into code
Types of input validation
Range Check
Presence Check
Format Check
Look-up table
Length Check
How is authentication defensive design
Confirms the identity of someone before they have access to the computer
How would you do authentication
Passwords
Limited amount of tires
Random letters in password
How should you maintain code
Comments
Sub-programs
Indentations
Naming conventions
Syntax error
An error in the grammatical rules of the code that produces an error result
Logic error
When the computer program is able to be run but not give the desired result
Iterative testing
The program is tested while it’s being developed, a par of it is tested and problems can be solved
Terminal testing
Program is tested at the end of the development process and the whole program is tested
Types of data testing
Normal
Boundary
Invalid
Erroneous
Normal data
Data that will give a result and what users will normally input
Boundary data
Values at the limit of the program
Invalid data
Data rejected by the program
Erroneous data
Data of the wrong data type