The following sum is constituted for each permutation p
1, p
2, p
3,..., p
9, p
A, p
B, p
10 of the duodecimal (base 12) integers 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, 10:
|p1-p2|+|p3-p4|+|p5-p6|+|p7-p8|+|p9-pA|+|pB-p10|
Determine the average value of all such sums.
(In reply to
Solution by Larry)
Interesting. Matlab won't even do perms of 12 numbers, complaining that the resulting vector is too long.
I forget what feature Python is lacking by itself without NumPy that, along with the necessity of familiarizing myself with which imports are needed for different things, keeps me from switching to Python. Matlab is just so more convenient. ... and installation of NumPy requires something else to do the installation.
|
Posted by Charlie
on 2022-12-19 07:56:17 |