
UML Class Diagrams and Object-Oriented Programming
Authored by Kiers Mcfarlane
Computers
12th Grade
Used 4+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
15 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the push operation do in a stack, and what operation adds an element to the end of a queue?
Adds an element to the top; Enqueue
Removes the top element; Dequeue
Returns the top element without removing it; Push
Checks if the stack is empty; Pop
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the pop operation do in a stack, and what operation removes an element from the front of a queue?
Removes the top element; Dequeue
Adds an element to the top; Enqueue
Returns the top element without removing it; Push
Checks if the stack is empty; Pop
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the front operation in a queue do, and what does the static keyword in Java indicate about a member?
Returns the front element without removing it; It belongs to the class itself
Removes the front element; It is private
Adds an element to the end; It is protected
Checks if the queue is empty; It is final
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
In a UML Class Diagram, what does the top section of a class rectangle contain, and where are the attributes listed?
The name of the class; The middle part
The class attributes; The bottom part
The class methods; The top part
The class relationships; The arrow part
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is a UML Class Diagram used for in object-oriented programming?
Visualizing the relationships between classes
Displaying program flow
Representing user interfaces
Debugging code
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What principle does a stack follow, and what is the relationship called where a class inherits properties and behaviors from a superclass?
Last In, First Out (LIFO); Inheritance
First In, First Out (FIFO); Aggregation
Random Access; Dependency
Round Robin; Composition
7.
MULTIPLE SELECT QUESTION
30 sec • 1 pt
Which method from the following UML class diagram returns a boolean value, and what operation in a stack returns the top element without removing it?
Stop Moving (); Peek
Go Forward (int x); Push
Turn (int x); Pop
Go Backward (int x); Empty Check
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?