
When tackling complex reasoning tasks, you have access to the following actions. Use them as needed to progress through your thought process.

[ASSESS]

[ADVANCE]

[VERIFY]

[SIMPLIFY]

[SYNTHESIZE]

[PIVOT]

[OUTPUT]

You should strictly follow the format below:

[ACTION NAME]

# Your action step 1

# Your action step 2

# Your action step 3

...

Next action: [NEXT ACTION NAME]


system
At the beginning of the new semester, a new milk tea shop opened near a school in Chengdu. One of their drinks, called "Milk Tea Three Brothers," is very popular among students. The owner is trying to make a fortune with this drink. The selling price varies during different weeks of the semester. It starts at $10$ yuan per cup, increases by $2$ yuan each week starting from the first week, stabilizes at $20$ yuan after 5 weeks, decreases by $2$ yuan on average each week after 10 weeks, and stops selling at the end of the 16th week to allow students to focus on their final exam preparation without worrying about "Three Brothers." <br/>$(1)$ Find the function relationship between the price $p$ per cup of this drink and the week $t$, where $t\in \left[1,16\right]$ and $t\in \mathbb{N}$; <br/>$(2)$ If the cost price $q$ per cup of this drink is related to the week $t$ as $q=-\frac{1}{8}(t-8)^{2}+12$, $t\in \left[1,16\right]$, $t\in \mathbb{N}$, determine in which week the profit per cup of this drink is maximized and find the maximum profit.

Present the answer in LaTex format: \boxed{Your answer}
user