. Find all possible missing distances. Input the sum of all possible distances (for example, if we had possibilities ; and the input would be ).
A road from Alphaville to Echoton passes through three other towns: Bravoton, Charlyville and Deltatown in that order. The distances along the road between pairs of these towns are given in kilometres. From smallest to largest, these ten distances are
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Straight away, we see that these distances are along the road, so any possible curvatures and twists in the road are included, and we do not worry about the direct distances if the road is not straight. The distances are between pairs of towns.
This means that 2 0 must be the distance between the first town and the last town (Alphaville and Echoton). The distance between any towns must not exceed 2 0 . Now, we need to find out which combinations of the other numbers work and which don't.
2 and 1 8 is an inevitable combination. The sole variation is the order of these numbers. Either the 2 or the 1 8 could be the distance between A and B with the other then being the distance between D and E. This also means that the 5 , 6 and, logically, 7 must be together ( 5 + 6 + 7 = 1 8 ) . This leaves us with the following possible number sequences 2 , 5 , 6 , 7 ; 2 , 5 , 7 , 6 ; 2 , 6 , 7 , 5 ; 2 , 7 , 6 , 5 ; 2 , 7 , 5 , 6 ; and 2 , 6 , 5 , 7 , as well as 7 , 6 , 5 , 2 ; 6 , 7 , 5 , 2 ; 5 , 7 , 6 , 2 ; 5 , 6 , 7 , 2 ; 6 , 5 , 7 , 2 ; and 7 , 5 , 6 , 2 .
5 and 15 is another inevitable combination. 5 cannot be in the middle (inside the 15) because to add up to 20, 15 would then need to be summed up with the 2 numbers on the side (which would be either 2 and 3 or 4 and 1), however, 1, 3 and 4 are not allowed. The 5 must also be on the opposite side from the two. For example, 5 cannot be the distance between A and C if the distance between A and B is 2. Otherwise, the distance between B and C would be 3, which is impossible in accordance with the problem’s terms.
We have deduced that 2 and 5 must be on the sides: either one could be the distance between A and B and the other then between D and E . We must now find the possible positions of 6. It can be the distance between either B and C or C and D. The 7 would fall back into the remaining position.
This, in turn, means that the 6, 7 and 2 must be together ( 7 + 6 + 2 = 1 5 ) . Now, of the sequences mentioned above, we have only got 2,6,7,5; 2,7,6,5, as well as 5,7,6,2 and 5,6,7,2 left. Now we can calculate the distances between non-adjacent towns (for example, between A and C or C and E). They are: 8, 12 and 13 (for 5,7,6,2, and 2,6,7,5) or 9, 11 and 13 (for 5,6,7,2 and 2,7,6,5).
Therefore, there are two different possible sequences:
a) 2 , 5 , 6 , 7 , 8 , 1 2 , 1 3 , 1 5 , 1 8 , 2 0 .
b) 2 , 5 , 6 , 7 , 9 , 1 1 , 1 3 , 1 5 , 1 8 , 2 0 .
So, all we have to do is add 7 + 8 + 1 2 + 1 3 + 7 + 9 + 1 1 + 1 3 .