Question: Suppose we have a set of numbers, $C=\{1,2,3,\dots,n\}$, and we have the function $\pi(x)$ that moves all elements to right by $x$ places iteratively, starting in the first element. If there are not $x$ more elements to the right, it goes back to the start.

For example, if $C=\{1,2,3,4,5\}$, then $\pi(1)$ applied to $C$ is $\{2,3,4,5,1\}$

Now for example, $A=\{1,2,3,4,5,6\}$ then $\pi(4)$ applied to $A=\{5,3,1,5,\dots\}$ so $\pi(4)$ applied to $A$ is $\{5,3,1\}$.

Now consider the set $Y=\{1,2,\dots,n\}$, $n\ge3$. How many $x$'s there are such that $\pi(x)$ applied to $Y$ doesn't not have the elements $1,2,3$ at the same time and are not repeated sequences?

What I mean by repeated sequences:

$C=\{1,2,3,4,5\}$ , $\pi(1) = \pi(6)$, so it's counted as 1.

Answer: 
Using coefficient extractors we get for the LHS

$$\sum\_{r=0}^n {n\choose r} {m+r\choose n}
= [z^n] (1+z)^m \sum\_{r=0}^n {n\choose r} (1+z)^r
= [z^n] (1+z)^m (2+z)^n.$$

We get for the RHS

$$\sum\_{r=0}^n {n\choose r} {m\choose r} 2^r
= \sum\_{r=0}^n {n\choose r} {m\choose m-r} 2^r
\\ = [z^m] (1+z)^m \sum\_{r=0}^n {n\choose r} 2^r z^r
= [z^m] (1+z)^m (1+2z)^n.$$

This last term is

$$\mathrm{Res}\_{z=0} \frac{1}{z^{m+1}} (1+z)^m (1+2z)^n.$$

There is no pole other than the one at zero and residues sum to zero so
this is

$$-\mathrm{Res}\_{z=\infty} \frac{1}{z^{m+1}} (1+z)^m (1+2z)^n
\\ = \mathrm{Res}\_{z=0} \frac{1}{z^2}
z^{m+1} \frac{(1+z)^m}{z^m} \frac{(2+z)^n}{z^n}
\\ = \mathrm{Res}\_{z=0} \frac{1}{z^{n+1}} (1+z)^m (2+z)^n
= [z^n] (1+z)^m (2+z)^n.$$

This is the claim.
This is another version of Phicar’s solution.

There are $n$ students and $m$ professionals. All professionals are member of chess club while students can be in the club or not. Suppose that we want to choose $n$ people from the club’s members to join a competition.

In the LHS, $r$ students are in chess club, $\binom{n}{r}$. Therefore, there are $m+r$ chess club members to choose from, $\binom{m+r}{n}$. Hence $\sum\_{r=0}^{n}{\binom{n}{r}\binom{m+r}{n}}$

In the RHS, $r$ professionals join the competition, $\binom{m}{r}$. Therefore, $n-r$ students must be members of the club and join the competition, $\binom{n}{n-r}=\binom{n}{r}$. The remaining $r$ students can be in the club or not, $2^{r}$. Hence $\sum\_{r=0}^{n}{\binom{n}{r}\binom{m}{r}2^{r}}$