0% found this document useful (0 votes)
66 views13 pages

4) Software Engineering

Uploaded by

bacexam229
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
66 views13 pages

4) Software Engineering

Uploaded by

bacexam229
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 13

*TM3541906F1PV1*

TM3541906F1PV1

TM354/D

Module Examination 2019

SOFTWARE ENGINEERING

Tuesday, 11 June 2019 2:30 pm – 5:30 pm

Time allowed: 3 hours

This examination is in TWO parts and you should attempt as many


questions as you can in BOTH parts. Your answers to each part should
be written in the blank answer book(s) provided.
Part 1
This part contains ten short questions. You should attempt ALL the
questions in Part 1.
The total score for Part 1 is 50 marks.
Part 2
This part consists of two longer questions. You should attempt BOTH
the questions in Part 2.
The total score for Part 2 is 50 marks.
At the end of the examination
Check that you have written your personal identifier and examination
number on each answer book used. Failure to do so will mean that
your work cannot be identified.
Put all your used answer books together with your signed desk record
on top. Fasten them in the top left corner with the round paper fastener.
Attach this question paper to the back of the answer books with the flat
paper clip.

Copyright © 2019 The Open University


PART 1 Answer ALL questions from this part of the examination.
Question 1 (a) List four characteristics or attributes that a software system should have in
order to be of high quality.
(2 marks)
(b) How can prototyping contribute to iterative development?
(3 marks)
Question 2 (a) Briefly explain the approach that agile takes to the documentation of
requirements.
(2 marks)
(b) How would you expect an agile team to interact with customers?
(3 marks)
Question 3 (a) Consider the following extract from a business description of a cinema
booking system.
Customers can buy tickets online for collection at the cinema, or in person at
the cinema. When buying online the customer identifies the chosen film and
the date and time of the showing. They indicate how many tickets of each
type (adult or child) they require. Child tickets are not available for films
classified ‘18’. For films classified 12A at least one adult ticket must be
purchased. The customer can choose where they sit by selecting seats from
a seating plan. Seats that are already booked will not be selectable. A non-
refundable card payment is made by the customer once they have
confirmed their seating choices.
From the description identify one business process and two business rules
in this domain.
(3 marks)
(b) What is the relationship between a business rule and a requirement?
(2 marks)
Question 4 People who would like to sell, view and buy properties can register as members
of a property trading website. The class model is shown in Figure 1.

Figure 1 Class model for a property trading website

2 TM354 June 2019


(a) Referring to Figure 1 explain why it is not possible to identify which specific
viewing led to a sale.
(2 marks)
(b) With reference to Figure 1, write an invariant in OCL that captures the rule
that a sale can only be made if the member who is buying the property has
viewed that property at least once.
(3 marks)
Question 5 This question refers to the class model in Figure 1.
The object diagrams in Figure 2 show the changes that are required in response
to the reassign salesperson use case.

Figure 2 Before and after object diagrams for reassign salesperson use case

Draw a sequence diagram for the reassign salesperson use case.


You may assume that the first message is sent from a user interface object to an
instance of the Viewing class.
(5 marks)

TM354 June 2019 TURN OVER 3


Question 6 A supermarket has a row of automated checkouts where customers can scan
their purchases before paying for them. Each checkout has a barcode reader,
screen, card payment machine and bagging area incorporating a scale.
When the checkout is powered up the barcode reader enters the ‘ready’ state.
Customers must then scan their items one by one by passing the item’s barcode
past the barcode reader. Each time that a barcode is read the barcode reader will
‘beep’ and then will not accept another reading until the scanned item has been
placed onto the scale and weighed (the actual weight can be compared to the
item’s recorded weight in the product database). If the weight is OK then the next
item can be scanned. If the weight is not OK then the customer must wait for a
manager check and reset the machine so that scanning can continue. When the
customer has scanned their last purchase they can make a card-payment. The
successful completion of this payment leaves the barcode reader ready for the
next customer.
Draw a statechart for the barcode reader.
(5 marks)
Question 7 Figure 3 shows the user interface of an app used to control the temperature in a
room.

Figure 3 Temperature controller app


(a) The app is an example of the model-view-controller (MVC) design pattern.
The controller is represented by the slider at the bottom. Outline how the
other components of the MVC pattern will be affected when a user moves
the slider.
(2 marks)
(b) Explain how the Observer pattern might be used in the MVC pattern.
(3 marks)

4 TM354 June 2019


Question 8 (a) Which three of the following statements about service-oriented architecture
(SOA) are true? (You do not need to provide explanations, just identify
which three are true.)
A. Services should hide details of their implementation.
B. Services use proprietary technologies rather than standard
communication protocols.
C. To use a service a client always needs to know its physical location.
D. Services should only have loosely defined interfaces.
E. A utility service is one that can be useful in a variety of applications.
F. Services support a flexible business model that can respond quickly to
new opportunities.
(3 marks)
(b) Suggest two response measures that might be relevant to a usability
scenario.
(2 marks)
Question 9 Compare the complexities of two following code extracts A and B, using first the
lines-of-code (LOC) metric and then the cyclomatic-complexity metric. Briefly
show your workings for the cyclomatic complexity values.
Write a brief sentence commenting on your findings.

Extract A
int max = a[0];
for (int i : a)
if (i > max) {max = i;}
int min = a[0];
for (int i : a)
if (i < min) {min = i;}
int range = max - min;

Extract B
float sx = 0;
float ssx = 0;
float n = a.length;
for (int x : a) {
sx = sx + x;
ssx = ssx + x*x;}
float vr = ssx/n - (sx/n)*(sx/n);

(5 marks)

TM354 June 2019 TURN OVER 5


Question 10 In a well-known international state of agile survey held each year there were 3
themes identified for 2018:

 Organisational culture matters


 Agile is expanding within the enterprise
 Customer/user satisfaction is of utmost importance.
Pick ONE of the following themes and discuss why it may be relevant to agile
software development.
(1) Why should organisational culture be important for the adoption of agile?
OR
(2) What are the appealing factors of agile that would trigger whole
organisations to think about adopting agile? OR
(3) How does agile contribute to customer and user satisfaction?
(5 marks)

6 TM354 June 2019


PART 2 Answer BOTH questions from this part of the examination. Each question carries
25 marks.
Question 11 This question concerns the development of a small software system. Figure 4
below outlines the problem domain.
Scenario
The Middletown Robotics Club
A small group of schools in Middletown are planning to start a joint robotics club,
the Middletown Robotics Club (MRC), which will open to students at any of the
schools involved. The organisers of club require a software system, the MRC
software system (MRCSS), to assist in its administration.
Club meetings will take place in a room of one of the schools involved and will be
held on either a weekday evening or a Saturday morning. A programme of the
times, dates and locations will be published on the MRC website at the start of
each term. The program will also give information about the maximum number of
places available at any particular meeting.
Each meeting will be led by a teacher and at least one other adult. The other
adult or adults may be teachers, or they may be volunteers who have been
registered with one of the schools in the scheme.
Places at a given meeting will be limited by the availability of the equipment
required, and so students will need to book for each meeting in advance, and be
allocated a place providing one is available. When a booking is made, a unique
reference number will be issued to the student. Students will also be able to
cancel a booking they have made, and to see a list of meetings for which they
have booked. To book for a meeting, to cancel attendance at a meeting or to see
a list of meetings, a student will need to log on to the MRC website with a
username and password issued to them by their own school; to make a booking,
the student will also need to identify the meeting they want to book; to cancel a
booking, the student will need to enter the reference number for the booking.
MRC administrators will need to be able to record details about a location; its
contact details, and the number of students it has equipment for. Administrators
will also need to be able to record details of teachers and volunteers, including
their names, contact details, how many club meetings they are willing to be
involved in, and which school they are from.
MRC administrators must also be able to create a program for a term,
distinguished by its year and term, 1, 2 or 3; for example '2019 3' for the third
term in 2019. Once a programme has been created administrators must be able
to add meetings, and for each meeting record the date and time, the venue, and
the adults who will be involved. Administrators must also be able to see a list of
all the meetings in a particular program, and modify or cancel a meeting.
Figure 4 Problem domain
(a) Draw an activity diagram for the process followed by a student to login to the
system and then to select one of the options to book a meeting, cancel a
meeting, or see a list of meetings. Your diagram should have swimlanes for
the student and the online system.
(7 marks)

TM354 June 2019 TURN OVER 7


(b) Complete the use case diagram in Figure 5 with all the use cases for the
Administrator actor and required associations.

Figure 5 Incomplete use case diagram for the proposed MRC software system
(6 marks)
(c) Give one example of a functional requirement for the MRC, together with a
potential non-functional requirement that could apply to the functional
requirement you have chosen, stating what category your non-functional
requirement belongs to.
(2 marks)
(d) What would be a fit criterion for the functional requirement you gave in (c)
above?
(1 mark)
(e) Table 1 below is an incomplete textual description of the use case book a
meeting from the proposed MRC software system.

Table 1

Identifier and name UC10 book a meeting


Initiator Registered student
Goal A booking will have been made for the student
for the chosen meeting.
Precondition The meeting is not full.
Postcondition A booking will have been made and the number
of available places for the meeting will have been
reduced by one.
Assumptions The student is logged on.

8 TM354 June 2019


Main success scenario

1 The student requests to book a meeting.

2 The system requests details.

3 ?

4 ?

5 ?

6 The system issues a reference number to the student.

Extensions

3.a.1 ?

Give descriptions for the missing steps.


(5 marks)
(f) Write two user stories for the proposed MRC software system in Figure 4.
(4 marks)

TM354 June 2019 TURN OVER 9


Question 12 Part (a) only of this question refers to the MRC software system.
(a) Figure 6 below shows an incomplete analysis model for the proposed MRC
software system described in Figure 4 (see Question 11).
Missing from this diagram are:
 two classes and their attributes,
 some relationships between existing classes
 relationships involving new classes.
Copy Figure 6 and add the missing classes, together with the attributes of
each class and any missing relationships between the existing classes and
with the new classes.
You should show the multiplicities at each end of the associations, but you
are not required to name the associations or to show role names.

Figure 6 Incomplete analysis model for the proposed MRC software system
(9 marks)

10 TM354 June 2019


(b) This part of the question is concerned with a small application used by a taxi
company to record bookings.
Figure 7 and Table 2 show respectively an analysis class diagram for the
application, and a use case make booking.

Figure 7 Analysis class diagram

Table 2 The make booking use case

Identifier and name UC3 make booking


Initiator Bookings clerk
Goal A new booking is created for an existing customer.
Precondition The customer must exist in the system.
Postcondition A new booking will have been created for the
customer, for the given date and time, pickup
address and destination address.
Assumptions None.
Main success scenario 1. The clerk requests the creation of a new booking.
2. The system displays the make booking page.
3. The clerk identifies the customer from a list, and enters
the date and time, pickup and destination addresses.
4. The system checks the details and requests confirmation
of booking.
5. The clerk confirms the booking.
6 The system records the booking and issues a job number.
Extensions 4.a.1 Details not valid. The clerk is notified and requested
to amend them; go to step 3.

TM354 June 2019 TURN OVER 11


Consider the make booking use case described in Table 2 and assume the
situation before and after is given by the snapshots in Figure 8.

Figure 8 Before and after snapshots


(i) Write the signature for a system operation makeBooking() in the class
TaxiFirm.
(1 mark)
(ii) Write the postcondition of the makeBooking() operation.
(4 marks)
(iii) Draw a sequence diagram for the interaction needed to fulfil the
postcondition of the make booking use case.
(6 marks)
(c) This part is about black box testing. You should assume Design by Contract
is being used.
A company reimburses employees who use their private cars for business
according to the following rates (Table 3).

Table 3 Travel expenses

Basic mileage rate 40p per mile


Passenger rate An additional 5p per mile
for each passenger
Distance fee An additional £15.00 for
journeys over 150 miles

A method
calculateFare(int miles, int passengers)
is required which will accept a distance in miles and a number of
passengers, both non-negative values, and calculate the travel expenses
claimable.
12 TM354 June 2019
Copy Table 4 below and add a further five black-box tests that would be
suitable for testing this method, using the same format as Tests 1 and 2.
You should choose your five tests with the aim of maximising the chances of
detecting any faults there may be in the coding of the method.

Table 4 Example tests

Test Input Expected Brief rationale for test


number output
1 miles: 0 £0.00 Extreme of subdomain
passengers: 0
2 miles: 50 £25.00 Typical values
passengers: 2
… … … …

(5 marks)

[END OF QUESTION PAPER]

TM354 June 2019 13

You might also like