Basics Flashcards
Why is productivity decreasing during development?
Increasing complexity
What is software entropy?
- difficult and costly to maintain
→ highly unpredictable
What are (4) attributes of bad code?
- Ridid
- Fragile
- Inseparable
- Opaque
What does rigid code mean?
One single modification requests modification of many modules
What does fragile code mean?
One modification breaks the whole system
What does inseparable code mean?
One module can’t be reused without using many others
What is opaque code?
During reading it’ts not clear what the code is doing and how
What are (3) reasons for writing bad code?
- Wrong priority (fast)
- Wring attitude (lazy)
- Missing knowledge
What is the broken window effect and what does it mean for our code?
One broken window starts process toward decay.
→ never stop cleaning
What are the (3) actions of code sense?
- reading code
- preparing code
- testing code
What is required for a code quality attitude (3)?
- Knowledge (best practices)
- Judgement
- Dicipline (clean everyday)
What are the two rules for writing good code?
- Leave code cleaner that you found it
2. Write code for the future you
What are the (4) steps of Test-Driven-Development?
- Preparing test
- Programming to pass test
- Refactoring
- Testing again
What is refactoring?
Improving code structure without changing it’s behavior