1. Which of the following are true for pattern?
a) It is a small collection of atomic units
b) They are ubiquitous throughout software development
c) All of the mentioned
d) None of the mentionedView Answer

Answer: c
Explanation: All of the mentioned are true.

2. Patterns are mostly used in which of the following?
a) Design in large
b) Design in Small
c) Coding
d) All of the mentionedView Answer

Answer: d
Explanation: All of the mentioned are used for patterns.

advertisement

3. Which of the following can a pattern operate on?
a) Emphasize the solutions
b) Identify and name abstract
c) Provide a target for recognition
d) All of the mentionedView Answer

Answer: d
Explanation: All of the mentioned are the ways in which a pattern can operate.

4. What does emphasizing solution actually mean for patterns to operate?
a) Discovering patterns rather than inventing them
b) Serves as exemplars to programmers
c) All of the mentioned
d) None of the mentionedView Answer

5. Which of the factors make a pattern portable?
a) Creating instances of some appropriate resource at run time
b) Presentation of two different user interface tool-kits
c) All of the mentioned
d) None of the mentionedView Answer

Answer: c
Explanation: All of the mentioned factors can be considered to make a pattern portable.

6. When there is a need to implement strategy pattern?
a) When a single task is implemented in variety of ways
b) When it is dependent on nature of inputs
c) All of the mentioned
d) None of the mentionedView Answer

Answer: c
Explanation: All of the mentioned ways are used to implement strategy pattern.

advertisement

7. Which of the following is used in Decorator design pattern?
a) Broder Wrapper
b) Scroll Wrapper
c) Text View
d) All of the mentionedView Answer

Answer: d
Explanation: All of the mentioned are used in Decorator design pattern.

9. Which of the following is for factory method behavioral characteristic?
a) Interpreter
b) Template method
c) Iterator
d) None of the mentionedView Answer

Answer: a
Explanation: Interpreter and Template method are for factory method.

10. How does a use of template allowed in components simplify things?
a) Reliability is enhanced
b) Coding time is increased
c) Testing is more complexed
d) All of the mentionedView Answer

Answer: a
Explanation: A template can enhance reliability, reduce coding time and simplify testing.

11. How is reliability enhanced when a template is allowed in component?
a) Once the template is incorrect, then templatized portion of every using component is correct
b) Once the template is correct, then templatized portion of every using component is correct
c) All of the mentioned
d) None of the mentionedView Answer

Answer: b
Explanation: Once the template is correct, then templatized portion of every using component is correct.

advertisement

12. How is Testing simplified when a template is allowed in component?
a) Each component has a standard structure
b) Each component has a complex structure
c) All of the mentioned
d) None of the mentionedView Answer

Answer: a
Explanation: Testing is simplified when a template is allowed in component because each component has a standard structure that all paths testing can exploit.

13. How is Flexibility enhanced when a template is allowed in the component?
a) Conforming components are largely interchangeable
b) Conforming components are not largely interchangeable
c) All of the mentioned
d) None of the mentionedView Answer

Answer: a
Explanation: Flexibility is enhanced when a template is allowed in component because conforming component are largely interchangeable.