题目内容

Alyssa would like to sell gift cards for specific coffee drinks. Gift cards obviously don't need to be brewed or prepared, but in all other respects, gift card purchases should be recorded as and behave the same as the purchases of regular drinks.

A. Template or Strategy pattern
B. Decorator pattern
C. Adapter or Facade pattern
D. Null Object pattern
E. Proxy pattern
F. Subclass inheritance with no other design pattern

查看答案
更多问题

Ben Bitdiddle is opening a tea shop next door, Tea or Nil, which will serve both coffee and tea. You'd like to adapt your code to also handle tea. Like coffee, tea must be brewed, prepared after brewing, and served, but the brewing and preparation processes are quite different than for coffee.

A. Template or Strategy pattern
B. Decorator pattern
C. Adapter or Facade pattern
D. Null Object pattern
E. Proxy pattern
F. Subclass inheritance with no other design pattern

The term "authentication" refers to

A. proving who you are
B. proving you're allowed to do something
C. proving you're allowed to do something BECAUSE of who you are
D. proving your identity via a third-party provider

Which of the following BEST describes why one would want to "minify" JavaScript?

A. To make JavaScript harder to decipher for circumventers who try to inspect the JavaScript code
B. To reduce the complexity of JavaScript into an easy-to-use library for faster development
C. To compress JavaScript code for faster page load times
D. To make ones JavaScript code more cross-browser compatible

Which, if any, of the following statements are TRUE regarding JSON objects in Rails apps?

A JSON object's properties must exactly match the corresponding ActiveRecord model
B. In an association such as Movie has-many Reviews, the owned objects must be returned in 1 or more separate
C. JSON object JSON objects can only be consumed by a JavaScript-capable client
D. None of the above are true

答案查题题库