Development Flashcards

1
Q

What are some key concerns for a software developer?

A
  • Following code convensions
  • Following techniques for coding in a team
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is the aim of code conventions?

A
  • Defines good practice
  • Code looks like it was written by one singular person rather than n people
  • Improves the maintainability of code
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What are some examples of code conventions?

A
  • Write name variables like this
  • Write comments like this
  • Organise contents of a class like this
    -Name files like this
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What are some good practices for writing code?

A
  • Check validity of inputs
  • Check array bounds
  • Name all constants that represent real world values
  • No code duplication
  • Functions do one thing
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What are the two different strategies for coding in a team?

A

Test driven development
Comment driven development

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is test driven development?

A

Before you write code, write tests. Code is finished when it passes test

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is comment driven development?

A

Before you write code, write comments. This allows for designing code before building and leads to properly commented code

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Give different methods of debugging

A

Use of breakpoints
Variable inspection
Trace tables
Print statements

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What are some strategies to overcome bug fixing?

A
  • Be systematic
  • Keep a log of what you’ve executed
  • Find ways to exclude possible causes
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Name some strategies to overcome bug fixing

A

Binary search
Code changes
Hypothesis testing
Walk away

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Explain binary search in terms of bug fixing strategy

A

Start in the middle of code, is the problem before or after?

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Code changes

A

DANGEROUS -> Comment out sections of code (leads to shotgun debugging)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is shotgun debugging?

A

Randomly changing code

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is hypthesis testing in the context of debugging strategies?

A

List hypothesis about what the problem could be

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What is paired programming?

A
  • One person thinks/checks while the other person codes
  • Take it in turns to write functions and change pairs for different tasks
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is a test plan?

A

Determines when a programmer has finished building something (used in TDD)

17
Q

What are the three types of test plan?

A

Development test plan
System test plan
Acceptance test plan

18
Q

What is a development test plan?

A

Prove that a class functions correctly

19
Q

What is a system test plan?

A

Proves the software meets specifications

20
Q

What is an acceptance test plan?

A

Proves software meets requirements

21
Q

Why do we use test plans?

A
  • Defines what counts as finished
  • Tests code before delivering it
  • Managers use it to estimate testing workload and schedule it (GANNT or PERT)
  • Testing document serves as evidence to clients
22
Q

What are the two types of testing we have?

A

Validation testing
Defect testing

23
Q

What is validation testing?

A

Test that shows the software produces the right answer

24
Q

What is defect testing?

A

Test that show the software doesn’t break