How many numbers can be formed with the digits $1, 6, 7, 8, 6, 1$ so that the odd digits always occupy the odd places? I am getting answer $9$ but the actual answer is $18$.
 A: As far as I think, the correct answer is $9$, let's see how:
There are two odd numbers $7$ and $1$(two times), so if you try to put these three numbers in three odd places, you ccan arrange them in $3!$ ways, but notice that $1$ occurs 2 times, so no. of arranginfg odd numbers at odd places equals $3!/2!=3$.
We are not over yet, because for each arrangement of odd numbers we can have corresponding arrangement of even numbers which again equals 3..
So, total nuumber of ways =$3\times3=9$
A: Assuming that you mean $6$-digit numbers with every digit appearing the same number of times it appears in the data that you have provided:
The number of ways to arrange $1,1,7$ in the odd places is $\frac{(2+1)!}{2!\times1!}=3$.
The number of ways to arrange $6,6,8$ in the even places is $\frac{(2+1)!}{2!\times1!}=3$.
Hence the total number of arrangements is $3\times3=9$.
A: We have 3 odd places and 3 odd numbers. So 3 odd numbers can be arrange in 3! ways. But we have 1 repeating 2 times. So we have $\frac{3!}{2!}$ = 3
Now we have 3 even places and 3 even numbers. So 3 even numbers can be arrange in 3! ways. But we have 6 repeating 2 times. So we have $\frac{3!}{2!}$ = 3
So we have = 3 * 3 = 9 ways. 
But there is one thing to note whether you are starting from left side or right side to count odd places.
So we have 2 ways.
Total ways = 2 * 9 = 18 ways.
