Bài làm của sinh viên
THI CUỐI KỲ 2 (2020-2021) PTTK HƯỚNG ĐỐI TƯỢNG
Học phần: Phân tích thiết kế hướng đối tượng - Học kỳ 2 năm học 2020-2021
Mã số sinh viên: 102160275
Họ tên: Nguyễn Lại Tam Vũ
Lớp: 16TCLC3
Nhóm: 19Nh13A
Thời gian bắt đầu: 06:56 25/08/2021
Thời gian nộp bài: 07:41 25/08/2021
Thời gian làm bài: 45:00
Tổng số câu hỏi: 40
Số câu làm đúng: 20
Số lần vi phạm: 0
Số lần không nhận dạng được: 0
Trạng thái nhận dạng: Không nhận dạng
Điểm: 5
Câu 1 (Thời gian trả lời: 00:55)
You are given the following clipping of a UML class diagram. Which of the following statements are
true?
A. Groups can only consist of persons, they cannot comprise of other groups.
B. It is possible to navigate from a person to the appointments that he is in charge of.
C. A participant that has been assigned to an appointment can be group and person at the
same time.
D. One group can consist of several persons.
Câu 2 (Thời gian trả lời: 00:55)
You are given the following sequence diagram. Which operations does class B have according to the
diagram?
A. z():void
B. x():void
C. x(void)
D. y():int
Câu 3 (Thời gian trả lời: 01:00)
Which of the following statements are true ?
A. If an object can only have one out of several associations, this may be modeled with a
{xor} relationship
B. You can specify the names of the roles the classes play in the relationship on the
association ends
C. A class must never have a relationship with itself
D. A role name is noted in the upper left corner of a class symbol
Câu 4 (Thời gian trả lời: 01:05)
How do you model the following situation with a UML use case diagram:
Father and son cook dinner. In the course of that, one of them always has to load the dishwasher. In
this approach, only the son does the cooking.
A. A
B. C
C. D
D. B
Câu 5 (Thời gian trả lời: 01:05)
You are given the following clipping of a UML class diagram. Which of the following statements are
true?
A. One tenant can rent two flats with one leasing contract.
B. One flat can be rented by multiple tenants with the same leasing contract.
C. One tenant can rent multiple flats with different leasing contracts.
D. One flat can be rented by multiple tenants with different leasing contracts.
Câu 6 (Thời gian trả lời: 01:15)
How do you model the following situation with a UML use case diagram: A travel booking is cancelled
by a staff member or by the department head (who also is a staff member).
A. C
B. D
C. B
D. A
Câu 7 (Thời gian trả lời: 00:55)
Which of the following statements about the given diagram clipping are true?
A. A inherits all of B's associations.
B. A can execute the same use cases as B.
C. B can execute the same use cases as A.
D. B inherits all of A's associations.
Câu 8 (Thời gian trả lời: 00:55)
Which of the following statements about the given diagram clipping are false?
A. Z inherits from Y, it is a specialized Y and can be executed by sub actors (descendants) of
X. A and B inherit the behavior of X, they are specialized X and can execute Y.
B. A and B can execute Y separately.
C. A or B can execute Z.
D. A and B execute Y together.
Câu 9 (Thời gian trả lời: 01:05)
How do you model the following situation with a UML class diagram: One team may consist of
several other teams.
A. C
B. B
C. A
D. D
Câu 10 (Thời gian trả lời: 00:45)
Which of the following statements about the given diagram clipping are true?
A. B is called "base use case".
B. A must not be abstract.
C. A inherits all relationships from B.
D. B inherits all relationships from A.
Câu 11 (Thời gian trả lời: 01:20)
You are given the following clipping of a UML class diagram. Which of the following statements are
true?
A. One flat can be rented by multiple tenants with different leasing contracts.
B. One tenant rents exactly one flat.
C. One tenant can rent multiple flats with different leasing contracts.
D. One tenant can rent the same flat several times with different leasing contracts.
Câu 12 (Thời gian trả lời: 00:55)
Which of the following statements are FALSE about Use Cases?
A. Use cases provide the basis of communication between sponsors and developers in
planning phase
B. Use cases description provides a good source to identify domain concepts
C. A fully-dressed use case should include both "whats" and "hows" so that they are ready
for "realization"
D. A use case is an interaction between a user and a system
Câu 13 (Thời gian trả lời: 00:45)
Which statements are false for a use case?
A. a use case may have many scenarios
B. good source for identifying use cases is external events
C. a use case captures some user-visible and non-visible functions
D. a use case can be traced to a discrete goal
Câu 14 (Thời gian trả lời: 01:30)
The following <<extend>>-relationship means, that ...
A. ... A can extend B.
B. ... A cannot be executed without B.
C. ... B can extend A.
D. ... B always has to invoke A.
Câu 15 (Thời gian trả lời: 00:50)
How do you model the following situation with a UML class diagram: The car fleet of a car rental
contains multiple cars, one car belongs to exactly one car fleet.
A. D
B. A
C. B
D. C
Câu 16 (Thời gian trả lời: 01:00)
What do you think you can show in a class diagram?
a) Groups of classes
b) The relationships between classes
c) The dynamic behavior of classes
d) The sequence of steps needed to complete a use case
A. a, c and d
B. a, b, c and d
C. a and b
D. a, b and c
Câu 17 (Thời gian trả lời: 01:30)
Which of the following statements about the given diagram are true?
A. If an instance of B is deleted, all contained instances of A are also deleted.
B. If an instance of A is deleted, all contained instances of B are also deleted.
C.
B is part of A.
D. If an instance of A is deleted, the contained instances of B are not affected.
E. A is part of B.
Câu 18 (Thời gian trả lời: 00:55)
You are given the following clipping of a UML class diagram. Which of the following statements are
true?
A. It is possible to navigate from a person to the appointments that he is in charge of.
B. A participant that has been assigned to an appointment can be group and person at the
same time.
C. If an appointment is deleted all references linked with it are deleted as well.
D. If a group is deleted all persons that are in that group are deleted as well.
Câu 19 (Thời gian trả lời: 01:10)
How do you model the following situation with a UML class diagram:
One team may consist of several other teams.
A. A
B. B
C. C
D. D
Câu 20 (Thời gian trả lời: 01:00)
How do you model the following situation with a UML2 use case diagram:
A student edits his user profile. In the course of that he can also change his password if he likes.
A. D
B. C
C. A
D. B
Câu 21 (Thời gian trả lời: 01:05)
You are given the following sequence diagram. Which traces are impossible?
A. b → c → a → a → b → c → d
B. a → b → c → d
C. d → a → b → c
D. b → a → c → d
Câu 22 (Thời gian trả lời: 01:05)
How do you model the following situation with a UML use case diagram: A mechanic does a car
service. During that service, it might be necessary to change the break unit.
A. D
B. C
C. B
D. A
Câu 23 (Thời gian trả lời: 00:45)
Within sequence diagrams ...
A. .... you can refer to other sequence diagrams
B. .... the behavior of one object is modeled.
C. ... time is no separate dimension.
D. .... the chronological process of one object is modeled.
Câu 24 (Thời gian trả lời: 00:55)
You are given the following clipping of a UML class diagram. Which of the following statements are
false?
A. D
B. C
C. B
D. A
Câu 25 (Thời gian trả lời: 01:30)
You are given the following state machine diagram. What is the value of x after the occurrence of the
event chain
e1 e2 e4 e2 e1?
A. 26
B. 12
C. 25
D. 13
Câu 26 (Thời gian trả lời: 01:15)
How do you model the following situation with a UML class diagram: There are exactly two kinds of
participants, namely members and guests. Guests are invited by members.
A. C
B. A
C. B
D. D
Câu 27 (Thời gian trả lời: 01:00)
How do you model the following situation with a UML class diagram: Every restaurant has at least
one kitchen, one kitchen is part of exactly one restaurant.
A. C
B. D
C. B
D. A
Câu 28 (Thời gian trả lời: 00:45)
Associations between classes are implemented by ... ?
A. function calls
B. types
C. functions
D. variables
Câu 29 (Thời gian trả lời: 01:10)
How do you model the following situation with a UML class diagram:
Every restaurant has at least one kitchen, one kitchen is part of exactly one restaurant.
A. B
B. A
C. C
D. D
D. D
Câu 30 (Thời gian trả lời: 00:50)
Which of the following combine to form an OOAD method?
a) Notation/Formal specification
b) Diagram
c) Process
d) View
A. a, b and d
B. a and b
C. a and c
D. a, b and c
Câu 31 (Thời gian trả lời: 01:05)
You are given the following clipping of a UML 2 class diagram. Which of the following statements are
FALSE?
A. One object of D may be associated with multiple objects of C.
B. There are no direct instances of A.
C. Two objects of D are associated with * objects of A.
D. One object of B must be associated with exactly two objects of D.
Câu 32 (Thời gian trả lời: 00:50)
Which of the following statements are true?
A. None of the above.
B. Maintaining different models for different perspectives will run into a risk of inconsistency
among models.
C. As models are refined, it is acceptable to use the same set of class diagrams for different
perspectives: conceptual, specification and implementation.
D. All of the above.
Câu 33 (Thời gian trả lời: 00:50)
Which statements are false for a use case?
A. a use case may have many scenarios
A. a use case may have many scenarios
B. good source for identifying use cases is external events
C. a use case must be initiated by an actor
D. a use case captures some user-visible and non-visible functions
Câu 34 (Thời gian trả lời: 00:55)
A sequence diagram is a two-dimensional chart. The two dimensions are ...
A. vertical: roles / horizontal: time axis
B. vertical: time axis / horizontal: roles
C. other answer
Câu 35 (Thời gian trả lời: 00:55)
Which of the following statements are FALSE about Use Cases?
A. Use cases provide the basis of communication between sponsors and developers in
planning phase
B. A fully-dressed use case should include both "whats" and "hows" so that they are ready
for "realization"
C. Use case diagrams are the primary tool to document requirements
D. Use cases description provides a good source to identify domain concepts
Câu 36 (Thời gian trả lời: 01:15)
In order to model the relationship “a course is composed of 5 to 20 students and one or more
instructors”, you could use:
a) To model systems using object-oriented concepts
b) To provide a process for software development
c) To support small-scale and large-scale analysis and design
d) To provide an insight into implementation mechanisms
A. Association
B. Composition
C. Realization
D. Aggregation
Câu 37 (Thời gian trả lời: 01:30)
Which of the following statements about the given diagram clipping are true?
A. B can execute the same use cases as A.
B. A inherits all of B's associations.
C. A can execute the same use cases as B.
D. B inherits all of A's associations.
Câu 38 (Thời gian trả lời: 01:00)
How do you model the following situation with a UML class diagram:
A fair is visited by at least one visitor. One visitor visits at least one fair.
A. A
B. B
C. C
D. D
Câu 39 (Thời gian trả lời: 00:50)
When to use Interaction Diagrams?
A. They are good to look at behavior of a single object across many use cases
B. When you want to look at the behavior of several objects within a single use case or
several use cases
C. All of the above
D. They are good at showing collaborations among objects; they are not so good at
conditions and looping
Câu 40 (Thời gian trả lời: 01:05)
Which statements are false for a use case?
A. a use case may have many scenarios
B. UML use case diagrams are designed to replace textual description since a picture is
better than a thousand words
C. a use case must be initiated by an actor
D. a use case can be traced to a discrete goal
Thoát