Determine the average value of $i_1i_2+i_2i_3+........+i_9i_{10}+i_{10}i_1$ taken over all permutations $i_1,$ $i_2,$ ......$,$$i_{10}$ of $1,$ $2,$.....$,$$10$.
I think there are $9!$ combination of such numbers $i_1i_2+i_2i_3+........+i_9i_{10}+i_{10}i_1$. But I started it with a huge calculation, but cannot find it out. I know there is a trick which I unable to find out. Please help me to solve this.
By the "linearity of expectation" principle, the answer is $10$ times the mean of $i_1i_2$. There are $90$ equally probable values of $(i_1,i_2)$, so the mean of $i_1i_2$ is $$\frac1{90}\sum_{i,j=1\atop i\ne j}^{10}ij =\frac1{90}\left(\sum_{i=1}^{10}\sum_{j=1}^{10}ij-\sum_{i=1}^{10}i^2\right) =\frac{55^2-385}{90}=\frac{88}3$$ so the original problem has answer $880/3$.