请问如果答案是240,为什么要除以2。
abcdea和abcdea有什么区别么?没有,因为是完全一样的;但也可以说有,因为可以理解为把第一个a和最后一个a互相换了。问题是换了对结果有影响么?排列顺序一点都没发生变化,所以P(6,6)应该除以2。
思路2. 俺老哥有另类思路:设6个数为 A, A, X, X, X, X . 按第一个A出现的位置,可有4种情况:
1) A, O, O, O, O, O . 另一个A在后四个O中挑位置,剩下四个O让四个X挑。 则为:4*P(4,4)= 96
2) O, A, O, O, O, O. 另一个A在后三个O中挑位置,剩下四个O让四个X挑。 则为:3*P(4,4)= 72
3) O, O, A, O, O, O. 另一个A在后两个O中挑位置,剩下四个O让四个X挑。 则为:2*P(4,4)= 48
4) O, O, O, A, O, O. 另一个A在只能在最后一个位置,剩下四个O让四个X挑。 则为:P(4,4) = 24
1) + 2) + 3) + 4) = 240 虽然烦些,但也让240为正确答案的可能性又大了一点
My comment:
I think it should be 480. There are two different ways to reach this conclusion:
1.) just follow what is stated above, 思路2, but for each situation, if you swap it head to toe, you will have 2x240=480 different ways.
2.) If all six alphabets are different, there are P(6,6) combinations. Now considering the case that two of these 6 alpahbets are identical and these two must be put together. Then you really have 5 different alpahbets to put into 5 different locations. So this is P(5,5). The difference of these two is what we are looking for. The correct answer is therefore P(6,6)-P(5,5).
Sorry that I do not know how to type in Chinese.