
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
A certain hotel has two types of rooms: double rooms priced at $200$ yuan each and triple rooms priced at $250 yuan each. A study group of $50$ students from a school stayed at the hotel, renting a certain number of rooms. Among them, there were $27$ male students and $23$ female students. If it is required that males and females cannot share a room, and all rented rooms must be fully occupied, find:<br/>
$(1)$ The minimum number of double rooms needed to minimize the cost;<br/>
$(2)$ Now, the hotel offers a 20% discount on double rooms and there are only $15$ double rooms left. In this case, find the minimum number of triple rooms needed to minimize the cost.

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