Counting total number of arrangements

Count the total number of arrangements of a,b,c,d,e,f such that

(a) a and b are side-by-side

(b) a occurring somewhere before b

For part (a), I know the answer is represented by $4!\times 10$ but I don't know the logic behind it, if someone could explain that it would be great.

For part (b), The a will occur before the b in half the cases so I can just say the following if I'm not wrong here.

$$6! \times \frac 1 2$$

Edit: something occured to me about part (a). If a and b had to appear in the order ab then it would just count as one element and the answer would be $5!$ but since a and b can also appear as ba it would just be $2 \times 5!$ which evaluates to the same thing as $4! \times 10$. Lemme know if my thinking is wrong here.

For the first part consider $a,b$ together as an element. Then there are $5$ elements and the total number of arrangements of $5$ elements is $5!$ and we can write $a,b$ together in $2$ ways, $a,b$ or $b,a$. So total number is $5! \times2.$

For part b your logic is right.

• Just made an edit with the same thing in mind – AFC Jan 29 '18 at 23:51

For a) consider {a,b} as one element. Thus, you now have effectively 5 elements: {a,b}, c, d, e, f. How many permutations of them are possible? (For instance, a possible permutation would be c{a,b}dfe). Now, pick an ordering between a and b; how many are possible now? (Edit: your thinking is right)

b) Like you said, half the arrangements will have a before b, so it is valid.

For part $(b)$, you are definitely right.

For part $(a)$, stick $a$ and $b$ together and consider it as one element. Then there are $5!$ ways to arrange $ab,c,d,e,f$. And don't forget that $a$ and $b$ can switch places so there are $2\cdot5!$ such arrangements.

Edit: Now, in both parts, your answer and methodology are correct. Well done :)