Multiple Choice
1. Which of the following statements pertaining to actors in use cases is FALSE? |
---|
In presence of generalization a more general actor can always replace the specialized one. |
One user might be represented by multiple actors in the same use case. |
Actor is a class of entities (human or computer), falling beyond the system boundaries and interacting with the system. |
One use case might involve multiple actors. |
2. After you initialise a new Git repository and create a file named hello.py, which of the following commands will not work if issued? |
---|
git add hello.py |
git commit -m “created a simple python program” |
git status |
git add . |
3. What is the major benefit of the incremental and iterative software development model? |
---|
It is easier to test and debug |
It is used when there is a need to release a product to the market early |
Customers can provide feedback to each increment, and product can be adapted |
Less Project Management Overhead |
4. Read the following description. “Customers of the garage can buy cars. Customers with a bad credit should pay an extra down payment”. Which of the following diagrams represent this description? |
---|
![](Picture1.png) |
![](Picture2.png) |
![](Picture3.png) |
> ![](Picture4.png) |
5. Which of the following is not true in the context of object-oriented design principles? |
---|
Encapsulation ensures that changes to the internal implementation of the class does not affect other parts of the application or clients accessing the class |
Abstraction helps to focus on the common properties and behaviors of objects |
Association is a mechanism to accurately represent the knowledge about the problem domain and discard irrelevant details |
Encapsulation hides the object state so that it can only be accessed through its public interface (methods) |
By abstracting the implementation, encapsulation reduces the dependencies so that a change to a class does not cause a rippling effect on the system |
6. What one of the following is not a responsibility of the product owner? |
---|
The product owner is responsible for ensuring that the product backlog always has the right set of user-stories needed |
The product owner can change the priority of the user-stories implemented |
The product owner provides an estimate in story points of the effort required to develop a user-story |
The product owner decides which user-stories are pulled into an iteration |
7. Which of the following statements is NOT true?
![](Picture5.png) |
---|
The diamond near A is called composition |
B is part of A |
If an instance of B is deleted, all contained object instances of A are also deleted |
If an instance of A is deleted, all contained object instances of B are also deleted |
8. A travel agency offers many trips e.g. 7-day Japan trip, 14-day Japan trip. Each trip comprises of a number of tours e.g., 7-day Japan trip includes 3 tours (tour to Hiroshima, tour to Mt Fuji, Tokyo city tour). The same tour can be joined by members from different trips e.g. the tour to Hiroshima can be part of both 7-day Japan trip and 14-day Japan trip. To model the above scenario, you decide that a trip can be made up of multiple tours and a single tour can be included in several trips. This situation is best modelled with a UML class diagram as: |
---|
![](Picture6.png) |
> ![](Picture7.png) |
![](Picture8.png) |
![](Picture9.png) |
9. An illustration of a one-to-many relationship would be: |
---|
A museum displays a list of art works |
A branch location has an internal Branch_ID code |
A balance field is totalled for all accounts for each person |
A person changes his/her primary address |
A student can enrol in several courses and each course has several students |
10. Which one of these represents a functional requirement? |
---|
All pages on a website must load in less than 2 seconds regardless of location of the customer |
The UI for the web application must adhere to HTML 5 guidelines and standards to ensure cross-platform portability |
Employees shall be forced to change their password the next time they log in if they have not changed it within the length of time established as “password expiration duration” |
The rate of failure occurrence of the Automated Teller Machine shall be 1 / 365 (1 failure in 365 days) |
Case Study
You are analysing requirements for an online developer’s forum.
To use the forum, a regular user must register providing a valid user-name and password.
Once registered, a user will be able to log into the system with their registered user-name and password and view the list of current discussion threads.
Discussion threads are grouped by topics e.g. python string functions, OO analysis, inheritance with Java.
User can click on any discussion thread and view or post messages under that thread.
Users can also search for relevant threads of discussion belonging to particular topic by doing a keyword search e.g. “inheritance java”.
A list of relevant discussion threads categorised under that topic will be displayed. Users can click on a search result and view or post messages under that thread.
Users can also create a new thread of discussion, under a particular topic but users can only post under existing topics.
Administrators can perform additional tasks such as delete or update messages posted by any user, close a discussion thread, create new topics and view statistics.
(a) Draw a use-case diagram that contains actors, use cases and their relationship from the scenario described above (5 marks)
(b) Draw a class diagram for the above problem domain. The class diagram must clearly identify all necessary classes (with attributes and methods) and relationships (with cardinalities) (10 marks)