If we have exactly one repetition is allowed, we start by choosing our three letters: $\binom{26}{3}$. We then choose a letter to be repeated in $\binom{3}{1} = 3$ ways. Finally, we permute our letters in $4!/2!$ ways by the multinomial distribution. By rule of product, we multiply, to get:
$$\binom{26}{3} \cdot 3 \cdot 4!/2!$$
Or add the four letter words with no repetitions (26*25*24*23) plus the ones with one repetition.
This is correct thinking. Notice that the words with no repetition are disjoint from words with exactly one repetition. So by rule of sum, you add $26!/(26-4)!$ with the quantity I noted above.
Suppose you have a $4$ letter string composed of, say, $1$ distinct and $3$ identical letters
There would be $\frac{4!}{1!3!}$ permutations, also expressible as a multinomial coefficient, $\binom{4}{1,3}$
Similarly, for $2$ distinct, $2$ identical, and $3$ distinct, $1$ identical,
it would be $\binom{4}{2,2}\;$ and $\binom{4}{3,1}$ respectively.
In the polynomial expression $4!(1+x/1!)^3(1+x+x^2/2!+x^3/3!)$,
the 4! corresponds to the numerator, whatever the combination; the first term in $( )$ corresponds to choosing one or more from $R,M,N$; and the other term corresponds to choosing $1,2,$ or $3 A's$
It will become evident why this approach works if we expand the first term in ( ), and compare serially with your case approach by just using the appropriate coefficients to get terms in $x^4$
$4!(1 + 3x + 3x^2 + x^3)(1 + x + x^2/2! + x^3/3!)$
To find the coefficient of $x^4$, consider the three cases that produce $x^4$
One from $R,M,N, 3A's : 4!\cdot3\cdot\frac{1}{3!} = 12$
Two from $R,M,N, 2A's : 4!\cdot3\cdot\frac1{2!} = 36$
Three from $R,M,N, 1A : 4!\cdot1\cdot 1 = 24$
Coefficient of $x^4 = 12+36+24 = 72$
We can now clearly see why the coefficient of $x^4$ in the expression automatically gives all possible permutations of $4$ letters
Best Answer
According to the comments , it appears that question is asking for how many possible words of length four there are using only the elements from the set of $\{A,A,L,G,E,B,R\}$.
When we construct the words ,we have two selection such that
All possible words with distinct letters (repeated letters not used) : If the letters of our words are distinct , select four letters from $\{A,L,G,E,B,R\}$ ,and order them in a row such that $$\binom{6}{4}4!=360$$
All possible words with repetition used: If repetiton is used , the repeating letters is only $A's$ , so select two more letters to construct your words,and order them in a row.Do not forget division rule because of repeating letters.Then , $$\binom{5}{2}\frac{4!}{2!}=120$$
As a result ,we have $360+120=480$ distinct words with your restriction at the end.