Sample questions
Question 1Easy
- Universal Machine Language
- Unified Markup Language
- Uniform Modelling Logic
- Unified Modeling Language
Answer: D. Unified Modeling Language
Explanation
UML is a standard visual language for modelling software systems.
Step-by-step solution
- UML is a standard visual language for modelling software systems.
- So the answer is: Unified Modeling Language.
Why the other options are wrong
- A. UML is not a machine language.
- B. It is not a markup language like HTML.
- C. Not the expansion.
Question 2Easy
In a use case diagram, an actor is
- A class
- A database table
- An external user or system that interacts with the system
- A function inside the code
Answer: C. An external user or system that interacts with the system
Explanation
Actors can be people, other systems or devices.
Step-by-step solution
- Actors can be people, other systems or devices.
- So the answer is: An external user or system that interacts with the system.
Why the other options are wrong
- A. Classes are in class diagrams.
- B. Tables are in ER diagrams.
- D. Functions are internal.
Question 3Medium
In UML, the symbol - before a member means
- Public
- Protected
- Private
- Static
Answer: C. Private
Explanation
A minus sign marks private visibility.
Step-by-step solution
- A minus sign marks private visibility.
- So the answer is: Private.
Why the other options are wrong
- A. Public is +.
- B. Protected is #.
- D. Static is shown by underlining.
Question 4Medium
Which UML diagram shows the actors and the functions of a system?
- Class diagram
- Use case diagram
- Sequence diagram
- Deployment diagram
Answer: B. Use case diagram
Explanation
A use case diagram shows who uses the system and what they can do.
Step-by-step solution
- A use case diagram shows who uses the system and what they can do.
- So the answer is: Use case diagram.
Why the other options are wrong
- A. A class diagram shows structure.
- C. A sequence diagram shows message order.
- D. A deployment diagram shows hardware.
Question 5Medium
Which diagram shows how objects interact in time order?
- Sequence diagram
- Class diagram
- Use case diagram
- Package diagram
Answer: A. Sequence diagram
Explanation
A sequence diagram shows lifelines and messages from top to bottom in order.
Step-by-step solution
- A sequence diagram shows lifelines and messages from top to bottom in order.
- So the answer is: Sequence diagram.
Why the other options are wrong
- B. A class diagram shows static structure.
- C. A use case diagram shows functions.
- D. A package diagram shows grouping.
Question 6Medium
A hollow diamond on a class diagram line represents
- Composition
- Inheritance
- Dependency
- Aggregation
Answer: D. Aggregation
Explanation
Aggregation is a weak whole-part relationship where the part can exist alone.
Step-by-step solution
- Aggregation is a weak whole-part relationship where the part can exist alone.
- So the answer is: Aggregation.
Why the other options are wrong
- A. Composition uses a filled diamond.
- B. Inheritance uses a hollow triangle.
- C. Dependency uses a dashed arrow.
Question 7Medium
In a use case diagram, the <<extend>> relationship means
- It is mandatory
- It connects two actors
- It removes a use case
- The extension use case adds optional behaviour
Answer: D. The extension use case adds optional behaviour
Explanation
Extend adds behaviour under a condition, such as Apply Coupon extending Checkout.
Step-by-step solution
- Extend adds behaviour under a condition, such as Apply Coupon extending Checkout.
- So the answer is: The extension use case adds optional behaviour.
Why the other options are wrong
- A. That describes include.
- B. It connects use cases.
- C. It does not remove.
Question 8Medium
Generalisation (inheritance) in UML is drawn as
- A dashed arrow
- A solid line with a hollow triangle at the parent
- A filled diamond
- A plain line with numbers
Answer: B. A solid line with a hollow triangle at the parent
Explanation
The hollow triangle points to the superclass.
Step-by-step solution
- The hollow triangle points to the superclass.
- So the answer is: A solid line with a hollow triangle at the parent.
Why the other options are wrong
- A. A dashed arrow is a dependency.
- C. A filled diamond is composition.
- D. A plain line is an association.
Question 9Hard
A realisation relationship in UML is drawn as
- A dashed line with a hollow triangle
- A solid line with a filled diamond
- A solid line with a large hollow triangle
- A plain solid line
Answer: A. A dashed line with a hollow triangle
Explanation
A class realises an interface using a dashed line with a hollow triangle.
Step-by-step solution
- A class realises an interface using a dashed line with a hollow triangle.
- So the answer is: A dashed line with a hollow triangle.
Why the other options are wrong
- B. A filled diamond is composition.
- C. A solid line with a hollow triangle is generalisation.
- D. A plain line is association.
Question 10Hard
- The time order of messages
- Instances of classes and their links at a point in time
- All use cases
- Hardware nodes
Answer: B. Instances of classes and their links at a point in time
Explanation
An object diagram is a snapshot of the system.
Step-by-step solution
- An object diagram is a snapshot of the system.
- So the answer is: Instances of classes and their links at a point in time.
Why the other options are wrong
- A. That is a sequence diagram.
- C. That is a use case diagram.
- D. That is a deployment diagram.
Practise all 25 questions free
The full question bank with timed practice, progress tracking and Vidya, your AI tutor. Free, no ads.
Open this topic in the app →