Multiple choice technology architecture

You are designing the Robot, which will have different Behaviors built in it. 1. Aggressive 2. Normal 3. Command What kind of design pattern you will use?

  1. Double Dispatch pattern

  2. OO Design pattern

  3. Robot Design pattern

  4. Strategy Pattern

  5. None of the above

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

The Strategy pattern encapsulates interchangeable algorithms or behaviors. A Robot can use Strategy to define Aggressive, Normal, and Command behaviors as separate strategy classes, allowing the robot to switch between them at runtime without modifying its core structure. Double Dispatch is for visitor-type operations, OO Design is too vague, and Robot Design isn't a standard pattern.