Answers Complete
What are the 5 most important concepts in software engineering?
Diseconomies of scale
Develop iteratively, integrate often
Abstraction
Strive for Low Coupling and High Cohesion
Catch errors early, closer to their origin (How?)
What exams must be taken and passed before becoming a professional engineer?
Fundamentals of Engineering
Subjects Exam
What is velocity?
The project velocity is the sum of the estimates for all the stories implemented in the last
iteration.
What is an exception?
Exceptions are used during program execution to signal errors and handle unusual or
unexpected events.
What is an assertion?
A predicate (a true-false statement) placed in a program to indicate that the developer
thinks that the predicate is always true at that place. If an assertion evaluates to false at
run-time, an assertion failure results, which typically causes execution to abort.
1. Pre-conditions
2. Post-conditions
3. Invariants
4. Internal invariants
What is the time-value of money?
$100 received today is worth more than $100 received one year from now.
If you don't believe this, give me $100 and I will gladly give you back $100 in one year.
That would be a bad deal for you because:
1 I could invest the money and keep the interest earned on your money.
2 If there was inflation in the economy during the time I was holding onto your money,
the purchasing power of the $100 I give back will be less than the $100 you gave me.
3 There is a risk I won't return the money.
For all these reasons, when discussing cash flows over time you have to take into
account the time value of money.
Can you put regular code in a catch block?
Yes, but it isn't advised.
What is a story?
A story defines the high level features of a product. Stories take the place of a
requirements document. Stories are similar to use cases but tend to be smaller. (Use
, cases are described in lesson 5.) It should be possible to describe a story on a 4x6
index card. It should be possible to implement a story in 1-3 weeks. A story should have
a business impact, be testable and estimable. A story doesn't include the complete
specification for a requested change. After a story is scheduled for implementation the
developer will work with the customer to establish complete specifications required to
make the change.
What are story points?
Story point is a arbitrary measure used by Scrum teams. This is used to measure the
effort required to implement a story. In simple terms its a number that tells the team how
hard the story is.
What is scrum?
Scrum is an iterative and incremental agile software development methodology for
managing product development.
What is test driven development?
TDD puts the activity of writing unit tests in front of coding:
Design ->Test -> Code
Writing tests before writing the code forces you to think about module design from the
outside looking in rather than from the inside looking out.
When you are ready to write some code you first write the test cases needed to fully test
the new functionality planned and then you write the code to pass the test cases.
How do you perform TTD?
1 Break requirements down into (very) small units of testable functionality.
2 Select a feature or small unit of functionality and write unit tests to test for the
presents of the desired behavior
3 Test the tests. Run the new tests to verify they fail. If the tests don't fail they are
defective.
4 Write the code
5 Rerun the tests to verify that they now succeed
6 Refactor. Remove duplication and make other non-functional enhancements to the
code. This step is driven by non-functional requirements
7 Repeat. Once cycle through these steps may take as little as 2 minutes
[Professionalism and TDD, IEEE Software, Martin 2007]
What are the three laws of TDD?
1 You may not write production code unless you've first written a failing unit test.
2 You may not write more of a unit test than is sufficient to fail.
3 You may not write more production code than is sufficient to make the failing unit test
pass.
Why is TDD utilized?
Just one more technique for finding errors earlier. Other: assertions, continuous
integration, code inspections.
Forces you to design the interface to your modules from the outside looking in. The test
case will be the first client of the code. If you make it easy to test, real clients will find it
easy to use.
Sketch a unit test!
...