Skip to content

Commit

Permalink
Update lab14.md: Add instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
ZheweiINK authored Apr 22, 2024
1 parent 7ded183 commit 372b38d
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions labs/lab14.md
Original file line number Diff line number Diff line change
@@ -1 +1,33 @@
# Lab 14 - Design Pattern Review

In this recitation, you will revisit three crucial design patterns: **Strategy**, **Template**, and **Decorator**. For each pattern, your task is to articulate key aspects, discuss scenarios where it is beneficial, highlight situations where it might not be the best choice, and demonstrate their use in UML diagram in the context of *Santorini's God Cards*.


## Deliverables
- [ ] Fill out the **Strategy** pattern template and answer follow-up questions of the TA
- [ ] Fill out the **Template** pattern template and answer follow-up questions of the TA
- [ ] Fill out the **Decorator** pattern template and answer follow-up questions of the TA

## Introduction
Throughout the semester, we've delved into many commonly used design patterns, including **Strategy**, **Template**, **Decorator**, **Composite**, **Observer**, **Proxy**, and **Adapter**.

In this lab, we will focus on the first three.

For each design pattern, you are expected to provide information in four sections:

- **Description**: Define the key characteristics that distinguish the pattern from others.
- **Pros**: Explain when and why you would choose this pattern. Focus on its advantages in terms of design principles and coding styles.
- **Cons**: Identify scenarios where choosing this pattern might be suboptimal. Focus on what makes it less preferable compared to alternative choices.
- **UML Diagram/Code snippet**: Draw an excerpt of a UML object model illustrating how you could use the design pattern to implement God Cards in Santorini. The model should show concrete classes that are plausible in the game, but an excerpt with only a small subset of methods or fields is fine, as long as it demonstrates the pattern.


## Instructions

### Download the cheatsheat

1. Create a copy of the template at https://docs.google.com/document/d/1o-j6jTDt1VLfUzJaF_kp-3blUSpXp-U7BGSPdN4vt08/edit?usp=sharing

### Tips

- Strive to devise your explanations before consulting external sources.
- While you are only required to explain three design patterns to the TA, feel free to continue filling in the information for the remaining patterns and seek clarification or assistance from the TA if needed.

0 comments on commit 372b38d

Please sign in to comment.