ICS52 - Introduction To Software Engineering
Midterm Exam – Summer, 2002
Name: ______Student ID: ______
- (20 points, 4 points each) Define the following terms, as used in software engineering:
- Program family.
A set of versions of a software product.
- High cohesion..
All elements (of a module) are closely related.
- Process iteration.
Repetition of parts of the process, often as requirements evolve. Two types are incremental development and spiral development.
- Module.
Hides a secret; communicates through well-defined interfaces; a software fragment; a provider of computational resources or services; a collection of routines, data, objects.
- Architectural design
Identification of the sub-systems that make up the system, and their relationships.
- (16 points) There are some similarities and differences between a class in Java and the Software Engineering concept of an Abstract Data Type (ADT).
Identify two similarities between Java classes and ADTs.
Both . . .
export a type
have an interface
have an internal state
hide implementation details
are based on information hiding
Identify two ways in which a valid Java class might not be a true ADT.
It might have just functions, no internal data or state, like java.util.Math or Debug from homework 2.
It might be a user interface element, such as a frame.
It might have public data members, which violates the principal of information hiding.
It might use inheritance.
It might be abstract, and therefore incapable of being instantiated.
- (12 points) One type of separation of concerns that is important in Software Engineering is modularity: dividing the software into modules, based on functionality, information hiding, and concern for reusability. Describe another type of separation of concerns that is important in Software Engineering. Give an example of how this type of separation of concerns might apply to a software system such as CAPA, and why it might lead to a better software product.
A wide range of answers were accepted for this problem. Scoring was based on four points for describing another type of separation of concerns; four points for giving an example; and four points for writing why this leads to better software. If your sheet is marked with three numbers, this indicates your score for each of the three parts.
- (21 points) Identify and briefly discuss three benefits of using the spiral model as opposed to the waterfall model.
1. Focuses early attention on the option of re-using existing software or software components. In the upper left quadrant and upper right quadrant, attention is on considering alternatives, constraints, and risks.
2. Accommmodates preparation for product growth, evolution, changes.
3. Incorporates quality objectives as integral parts of the process and not as side-effects.
4. Focuses on eliminating errors and unattractive alternatives early on.
5. Answers the process ``how much is enough'' question. The spiral starts with a hypothesis that a particular goal (or set of goals) could be improved by a software effort. It terminates when the hypothesis is proved false (cost of continuing judged greater than benefit) or true (installation).
6. Maintenance is not a second-class citizen in the process, but starts a new cycle.
7. The incremental approach is more suited towards families of applications.
8. It encourages a prototyping approach which is well suited for addressing user interfaces. Gets early user feedback based on prototypes.
9. Its prototype-based approach avoids the risk of spending too much time on not-so-important aspects and helps concentrate attention on the relevant issues and risks.
10. Recognizes that specification and implementation are inevitably intertwined.
- (16 points) Select one of the principles of software engineering discussed in the lecture (other than “separation of concerns”), and one of the architectural models presented in Chapter 10 or in lecture (other than “abstract machine”). Briefly define each, and then explain how the principle you selected is exhibited in the model you selected.
The answers given here are just examples; obviously there were many ways to answer this question.
Principle and definition: Abstraction – focusing on what is important and ignoring details.
Model and definition: Client - server model – client sub-systems communicate with server sub-systems (and not with each other). Clients make requests to servers, and servers respond with appropriate information.
Explanation:
What is important in the client-server model is the nature of the request and response between clients and servers, and not details such as how they communincate, or where the clients and servers are located.
- (3 points) When a module M is decomposed into other modules, we say that these other modules are used to
- implement M
- interface M
- abstract M
- design M
- export M
- (3 points) To achieve a good design, modules should have (choose one.)
- low cohesion and low coupling.
- low cohesion and high coupling.
- high cohesion and low coupling.
- high cohesion and high coupling.
E.either A. or D.
- (3 points) The textbook lists several required aspects of a software requirements document (due to Heninger, 1980). Which of the following is not on that list?
- It should specify the algorithms and data structures to be used. p. 116.
- It should be easy to change.
- It should record forethought about the life cycle of the system.
- It should characterise acceptable responses to undesired events.
- It should specify only external system behaviour.
- (3 points) Which of the following is not on Boehm’s list of software risk factors?
- Over-emphasis on the requirements phase.
- Personnel shortfalls.
- Gold plating.
- Developing the wrong user interface.
- Unrealistic schedules and budgets.
- (3 points) Which of the following activities would be associated with the upper left hand quadrant of the spiral model? (Choose one.) see p. 54
- Prototyping and resolving risks.
- Acceptance testing.
- Determining objectives.
- Developing software requirements.
- Software product design.