The Art of Dictionary Ranking
A Combinatorial Journey
Welcome, aspiring mathematician! Today, we are going to unravel the mystery of dictionary ranking. It is not just about counting; it is about the elegance of systematic order.
Imagine you are a librarian, and you have been tasked with organizing words formed by the letters of the word SMALL. You need to find exactly where SMALL sits in the dictionary. Let us embark on this journey together.
Phase 1
The Alphabetical Foundation
Before we can count, we must organize. The word SMALL consists of the letters S,M,A,L,L.
To find its rank, we must first arrange these letters in strict alphabetical order. Our sorted set is A,L,L,M,S.
Notice something crucial here: the letter L appears twice. This repetition is the heartbeat of our calculation. Whenever we arrange these letters, we must account for the fact that swapping the two Ls does not produce a new, distinct word.
Phase 2
The Systematic Sweep
In a dictionary, words are ordered by their first letter, then their second, and so on. To find the rank of SMALL, we must count every single word that comes before it by 'fixing' the first letter and counting all possible permutations of the remaining letters.
First, let us count all words starting with A. If we fix A at the first position, we have four slots left to fill with the remaining letters {S,M,L,L}.
The number of ways to arrange these is given by the formula for permutations of a multiset:
These 12 words all come before any word starting with L,M, or S.
Next, we move to words starting with L. If we fix L at the first position, the remaining letters are {S,M,A,L}.
Since all these four letters are distinct, the number of arrangements is simply 4!=24. These 24 words also precede our target.
Then, we consider words starting with M. Fixing M leaves us with {S,A,L,L}.
Again, we have the repetition of L, so the number of arrangements is:
Phase 3
The Precision Phase
Now, we reach the letter S. Our target word SMALL starts with S, so we freeze S at the first position and move to the second letter. The alphabetical order for the second position is A,L,M.
If the second letter is A, we have the prefix SA. The remaining letters are {M,L,L}. The number of arrangements is:
If the second letter is L, we have the prefix SL. The remaining letters are {M,A,L}. These are all distinct, so we have 3!=6 arrangements.
Finally, we reach the prefix SM. This matches the first two letters of SMALL! We freeze M and look at the third position.
The alphabetical order of the remaining letters {A,L,L} is A,L,L. The first choice is A, which matches the third letter of SMALL.
We freeze A. The remaining letters are {L,L}. The only way to arrange them is LL. Thus, we have found our word: SMALL. This is the very next word in our sequence, so we count it as 1.
The Grand Summation
To find the final rank, we simply sum all the counts we have meticulously gathered:
The rank of the word SMALL is 58th.
You have successfully navigated the dictionary! Remember, the key to these problems is not speed, but the systematic, step-by-step 'fixing' of letters. Keep practicing, and you will master these combinatorial puzzles in no time.