In how many ways can six letters be removed from "SIXSIXSIX" to make the string "SIX"? My answer:
10
My reasoning:
I used a decision tree to list all of the possible ways and counted them.

*

*SIX______

*SI___X___

*SI______X

*S___IX___

*S___I___X

*S______IX

*___SIX___

*___SI___X

*___S___IX

*______SIX

Is there a more mathematical way of getting this result?
 A: Let $s$ be a string of $n$ distinct letters. The number of not necessarily contiguous subsequences of ($s$ repeated $k$ times) that read $s$ is the same as the number of $n$-multisubsets of $[k]$ (length-$n$ combinations with replacement of $\{1,\dots,k\}$ because there is a bijection: given the multisubset $a_1\dots a_n$ in nondecreasing order pick the $i$-th letter of the $a_i$-th repetition of $s$.
EIGHT EIGHT EIGHT EIGHT EIGHT EIGHT, 22356
      ^^      ^            ^      ^

Therefore the number of ways is $\binom{n+k-1}{k-1}$. In your case $n=k=3$, giving $10$.
A: We count equivalently the number of ways to select three letters from left to right to form the word $SIX$. In order to do so we mark for each letter the position
\begin{align*}
\begin{array}{ccccccccc}
S&I&X&S&I&X&S&I&X\\
1&1&1&2&2&2&3&3&3
\end{array}\tag{1}
\end{align*}

We obtain
\begin{align*}
\color{blue}{\sum_{X=1}^3\sum_{I=1}^X\sum_{S=1}^I1}&=\sum_{1\leq S\leq I\leq X\leq 3}1\tag{2}\\
\end{align*}
We observe

*

*We can choose $X$ at position $1$,$2$ or $3$. Depending on that we can select $I$ at position $1$ up to that of $X$ and similarly we can choose $S$ at position $1$ up to the position of $I$.


*The number of summands given by the index range $$\color{blue}{1\leq S\leq I\leq X\leq 3}$$ of (2) is the number of ordered tripels $(S,I,X)$ between $1$ and $3$ with repetition. This number is given by the binomial coefficient
\begin{align*}
\binom{3+3-1}{3}=\binom{5}{3}\color{blue}{=10}
\end{align*}

