sdp5 patterns

Descripción

SDP5 Test sobre sdp5 patterns, creado por Csse 1502 el 21/11/2017.
Csse 1502
Test por Csse 1502, actualizado hace más de 1 año
Csse 1502
Creado por Csse 1502 hace alrededor de 7 años
243
1

Resumen del Recurso

Pregunta 1

Pregunta
The observed pattern is?
Respuesta
  • Structural
  • Creational
  • Behavioral
  • Executional

Pregunta 2

Pregunta
The Factory pattern is?
Respuesta
  • Creational
  • Structural
  • Executional
  • Behavioral

Pregunta 3

Pregunta
In the pattern, we create objects which represent various strategies and a context object whose behavior varies as per its strategy object. The strategy object changes the executing algorithm of the context object?
Respuesta
  • Memento
  • Adapter
  • Builder
  • Strategy
  • Facade

Pregunta 4

Pregunta
Single responsibility of principle?
Respuesta
  • Requires that methods that are present in base classes must also be present in derived classes
  • Requires that object interfaces only include methods that will be needed by most implementers
  • Helps make changing an object easier
  • helps ensure that objects are highly reusable
  • Helps ensure that objects are easy to extend without requiring change to the original object

Pregunta 5

Pregunta
Which of the patterns refers to creating duplicate object while keeping performance in mind?
Respuesta
  • Composite pattern
  • Facade Pattern
  • Builder pattern
  • Prototype pattern

Pregunta 6

Pregunta
The open close principle?
Respuesta
  • Helps make changing an object easier
  • Helps ensure that objects are highly reusable
  • Requires that methods that are present in base classes must also be present in the derived classes
  • Requires that object interfaces only include methods that will be needed by most implementers
  • Helps ensure that objecs are easy extend without requiring change to the original object

Pregunta 7

Pregunta
Which of the following is not a software engineering risk?
Respuesta
  • The code for sort algorithm is overly complex
  • The server may not scale to 1000 users
  • We do not adequately understand our customer's needs
  • The system is working fine, but if we try to change anything it seems to always break something else

Pregunta 8

Pregunta
A real life example could be a case of card reader which acts as the Pattern between memory card and a laptop. You plugin the memory card into card reader and card reader into the laptop so that memory card can be read via laptop?
Respuesta
  • Builder
  • Facade
  • Memento
  • Adapter
  • Observer

Pregunta 9

Pregunta
The pattern works as a bridge between two incompatible interfaces. This pattern involves a single class which is responsible to join functionalities of independent or incompatible interfaces?
Respuesta
  • Adapter
  • Facade
  • Builder
  • Observer
  • Memento

Pregunta 10

Pregunta
A design pattern _______
Respuesta
  • all
  • useful in - how a software problem was solved by a developer
  • gives examples of code that used the pattern
  • a general reusable solution to a commonly occurring problem

Pregunta 11

Pregunta
Name types of design patterns?
Respuesta
  • Creational, Structural, Behavioral
  • Creational, Executional, Structural
  • Creational, Behavioral, Executional
  • Behavioral, Executional, Structural

Pregunta 12

Pregunta
Why are Patterns important?
Respuesta
  • they capture expert design knowledge
  • All
  • None
  • make it accessible to both novices and other experts

Pregunta 13

Pregunta
Liskov’s substitution principle?
Respuesta
  • Helps ensure that object are easy to extend without requiring change to the original object
  • helps ensure that objects are hihtly reusable
  • Helps make changing an object easier
  • Requires that object interfaces only include methods that will be needed by most implementers
  • Requires that methods that are present in base classes must also be present in the derived classes

Pregunta 14

Pregunta
Upper case tools to support later activities such as programming, debugging and testing?
Respuesta
  • True
  • False

Pregunta 15

Pregunta
The Dependency inversion principle?
Respuesta
  • Requires that methods are present in base classes must also be in the derived classes
  • Helps ensure that objects are highly reusable
  • Helps make changing an object easier
  • Helps ensure that objects are easy to extend without requiring change to the original object
  • Requires that object interfaces only include methods that will be needed by mosty implementers

Pregunta 16

Pregunta
Can we create a clone of a singleton object?
Respuesta
  • Yes
  • No

Pregunta 17

Pregunta
which pattern does this object model represent
Respuesta
  • Singleton Pattern
  • Builder Pattern
  • Facade Pattern
  • Prototype Pattern

Pregunta 18

Pregunta
Which pattern does this object model represent?
Respuesta
  • State pattern
  • Facade pattern
  • Composite pattern
  • Builder pattern

Pregunta 19

Pregunta
Which pattern does this object model represent?
Respuesta
  • Strategy Pattern
  • Observer Pattern
  • State Pattern
  • Composite Pattern

Pregunta 20

Pregunta
Which pattern does this object model represent?
Respuesta
  • Facade pattern
  • Strategy pattern
  • Composite pattern
  • Builder pattern

Pregunta 21

Pregunta
Which pattern does this object model represent?
Respuesta
  • Facade pattern
  • Singleton pattern
  • State pattern
  • Strategy pattern
  • Composite pattern

Pregunta 22

Pregunta
Define one to many dependency between objects so that when one changes state, all its dependents are notified and updated automatically
Respuesta
  • Composite pattern
  • Observer pattern
  • Strategy pattern
  • State pattern

Pregunta 23

Pregunta
The Interface Segregation Principle ?
Respuesta
  • Hhelps make changing an object easier
  • Helps ensure that object are easy to extend without requiring change to the original object
  • Helps ensure that objects are hihtly reusable
  • Requires that methods are present in base classes must also be in the derived classes
  • Requires that object interfaces only include methods that will be needed by most implementers

Pregunta 24

Pregunta
The Pattern is used where we need to treat a group of objects in similar way as a single object
Respuesta
  • Composite
  • Observer
  • Facade
  • Memento
  • Builder
Mostrar resumen completo Ocultar resumen completo