1. ## Permutations

How many permutations of the string ABCDEFG are there where A is somewhere before B?

2. Originally Posted by alephnull
How many permutations of the string ABCDEFG are there where A is somewhere before B?
Here is strong hint: "half the time A comes before B"

3. $P_{n}=n!$
If A is the first letter you have $P_{6}$ posibilities.
If A is the second letter you have $5 \cdot P_{5}$ posibilities.
If A is the third letter you have $4 \cdot P_{5}$ posibilities.
If A is the fourth letter you have $3 \cdot P_{5}$ posibilities.
If A is the fifth letter you have $2 \cdot P_{5}$ posibilities.
If A is the sixth letter you have $P_{5}$ posibilities.
If A is the seventh letter you have no posibilities.

So, your answer is $P_{6}+5 \cdot P_{5}+4 \cdot P_{5}+3 \cdot P_{5}+2 \cdot P_{5}+P_{5}=6!+5!(5+4+3+2+1)=5!(6+5+4+3+2+1)=5!\cd ot 21=2520$