Chapter 12 UML and Patterns – absolute java test bank
Download file with the answers
Chapter 12 UML and Patterns - absolute java test bank
1 file(s) 34.66 KB
Not a member!
Create a FREE account here to get access and download this file with answers
Chapter 12
UML and Patterns
Multiple Choice
1) UML is a graphical language that is used for designing and documenting software created within the _____________ framework.
(a) top-down programming
(b) bottom-up programming
(c) structured programming
(d) object oriented programming
2) The first section of a UML class diagram specifies the:
(a) class members
(b) class name
(c) class methods
(d) class modifiers
3) The second section of a UML class diagram specifies the:
(a) class members
(b) class name
(c) class methods
(d) class modifiers
4) The third section of a UML class diagram specifies the:
(a) class members
(b) class name
(c) class methods
(d) class modifiers
5) In a UML class diagram, the tilde (~) indicates:
(a) public access
(b) protected access
(c) private access
(d) package access
6) In a UML class diagram, the minus (-) indicates:
(a) public access
(b) protected access
(c) private access
(d) package access
7) In a UML class diagram, the plus (+) indicates:
(a) public access
(b) protected access
(c) private access
(d) package access
8) In a UML class diagram, the sharp (#) indicates:
(a) public access
(b) protected access
(c) private access
(d) package access
9) The arrowheads in an inheritance diagram point:
(a) North
(b) South
(c) East
(d) West
10) Any construct that allows you to cycle through all the items in a container is called:
(a) Pointer
(b) Instance variable
(c) Iterator
(d) All of the above
11) An example of a container is a/an:
(a) array
(b) vector
(c) linked list
(d) all of the above
True/False
1) Pseudocode is a mixture of programming language and English.
2) UML was designed to be used with structured programming methodology.
3) Class diagrams must contain all class members.
4) A container is a class whose objects hold multiple pieces of data.
5) Any construct that allows you to cycle through all the items in a container is an iterator.
6) The Adaptor pattern transforms one class into a different class without changing the underlying class.
7) In a quick sort algorithm, a value called a splitting value is an arbitrarily selected value from the array to sort.
Short Answer/Essay
1) Define pseudocode.
Answer: Pseudocode is a combination of English like statements and high-level programming statements used to describe a software component.
2) Draw a UML class diagram for a class that represents a sphere.
Answer:
3) Draw a UML class diagram for a class that represents a savings account.
Answer:
4) Draw a UML inheritance diagram for possible classes used to represent a bank account.
Answer:
Leave a reply