
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
In the second year of junior high school this semester, a basketball game was held. In order to better train the participating athletes, the sports department plans to purchase two brands of basketballs, brand A and brand B. It is known that the unit price of brand A basketball is $40$ yuan lower than the unit price of brand B basketball. The quantity of brand A basketball purchased with $4800$ yuan is $\frac{3}{2}$ times the quantity of brand B basketball purchased with $4000$ yuan.<br/>$(1)$ Find the unit prices of brand A and brand B basketballs.<br/>$(2)$ If the school plans to purchase a total of $90$ brand A and brand B basketballs, and the quantity of brand B basketballs is at least twice the quantity of brand A basketballs, and the total cost of purchasing both brands of basketballs does not exceed $17200$ yuan. How many purchasing plans does the school have?<br/>$(3)$ Under the conditions of $(2)$, the store is preparing to offer a discount on brand B basketballs, with a discount of $a$ yuan $\left(30 \lt a \lt 50\right)$ per brand B basketball. The price of brand A basketball remains unchanged. Which purchasing plan should the school adopt to minimize the total cost?

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