All the arrangements, with or without meaning, of the word FARMER are written excluding any word that has two R appearing together. The arrangements are listed serially in the alphabetic order as in the English dictionary. Then the serial number of the word FARMER in this list is _________.
We begin by writing the six letters of the word FARMER in strict alphabetical order. In English dictionary order we have Remember that the letter occurs twice while every other letter occurs once.
In the required list we include all six-letter arrangements of these letters except those in which the two ’s stand next to each other. Our task is to find how many valid words appear before the given word FARMER, and then add one for FARMER itself.
Step 1 : fixing the first letter. The first letter of FARMER is . All words that start with letters alphabetically smaller than will certainly come before FARMER. The letters smaller than are and (two letters).
Suppose we fix such a smaller letter (say ) in the first place. We must then arrange the remaining five letters without letting the two ’s touch.
We first arrange the three non- letters in every possible order. Because they are all distinct, the number of such orders is
Whenever these three letters are written, they create “gaps’’ (one before the first letter, two between consecutive letters, and one after the last letter). To keep the two ’s apart, we simply choose any two of these four gaps and drop one into each chosen gap. Because the ’s are identical, the only decision is the choice of gaps, which can be done in ways.
Hence the total number of valid words that start with a fixed smaller letter such as is
The same calculation holds if the first letter is , so we obtain
valid words whose first letter precedes . All those 72 words will appear before FARMER.
Step 2 : fixing the first two letters as . With the first letter now forced to be , we turn to the second position. The second letter in FARMER is . Among the unused letters none is alphabetically smaller than , so no additional words are formed here. Our running count stays at words.
Step 3 : fixing the first three letters as and choosing the third. The third letter in FARMER is . The unused letters are . Letters alphabetically smaller than are and . We look at each choice in turn.
(i) Take as the third letter, giving the prefix . The remaining letters are . Among the ordinary permutations of these three letters, only keeps the two ’s apart, so exactly one valid word is produced.
(ii) Take as the third letter, yielding the prefix . The remaining letters are , and again only is acceptable. Thus a second valid word is obtained.
Hence
additional words appear before any word that actually has as its first three letters. Adding these two words raises the count to
Step 4 : fixing the prefix and choosing the fourth letter. The fourth letter in FARMER is . After the prefix the unused letters are . Among these, the letter alphabetically smaller than is only .
If we select for the fourth place, the prefix becomes and the leftover letters are and . Because there is now only one remaining, there is no danger of placing two ’s together. The two distinct letters and can be arranged in
ways. Thus two more valid words precede FARMER, bringing the running total to
Step 5 : fixing the prefix . With the fourth letter matching FARMER, the remaining letters are and . The fifth letter in FARMER is . Since no unused letter is alphabetically smaller than , no new words are gained here.
The prefix now exactly matches , leaving one final to be placed, which is allowed because it sits after an and is therefore not adjacent to another .
Step 6 : counting FARMER itself. All the words counted so far (76 of them) precede FARMER. Consequently, the word FARMER occupies position
So, the answer is .
Tagged Arrangements with restrictions. Machine-assigned, so read it as a strong shortlist rather than a verdict.