# Difference between revisions of "2020 AIME I Problems/Problem 5"

Note: Please do not post problems here until after the AIME.

## Problem

Six cards numbered $1$ through $6$ are to be lined up in a row. Find the number of arrangements of these six cards where one of the cards can be removed leaving the remaining five cards in either ascending or descending order.

## Solution 1

Realize that any sequence that works (ascending) can be reversed for descending, so we can just take the amount of sequences that satisfy the ascending condition and multiply by two.

If we choose any of the numbers $1$ through $6$, there are five other spots to put them, so we get $6 \cdot 5 = 30$. However, we overcount some cases. Take the example of $132456$. We overcount this case because we can remove the $3$ or the $2$. Therefore, any cases with two adjacent numbers swapped is overcounted, so we subtract $5$ cases (namely, $213456, 132456, 124356, 123546, 123465$,) to get $30-5=25$, but we have to add back one more for the original case, $123456$. Therefore, there are $26$ cases. Multiplying by $2$ gives the desired answer, $\boxed{052}$.

-molocyxu

## Solution 2 (Inspired by 2018 CMIMC combo round)

Similar to above, a $1-1$ correspondence between ascending and descending is established by subtracting each number from $7$.

We note that the given condition is equivalent to "cycling" $123456$ for a contiguous subset of it. For example,

$12(345)6 \rightarrow 125346, 124536$

It's not hard to see that no overcount is possible, and that the cycle is either $1$ "right" or $1$ "left." Therefore, we consider how many elements we flip by. If we flip $1$ or $2$ such elements, then there is one way to cycle them. Otherwise, we have $2$ ways. Therefore, the total number of ascending is $1 + 2 + 2(3 + 4 + 5 + 6) = 26$, and multiplying by two gives $\boxed{052}.$ ~awang11