Maths Olympiad Prep

Library / /319 of 520

Combinatorics Difficulty 5.4 AIME, harder Find the answer

5. Let the sequence of natural numbers from 181 \sim 8 be a1,a2a_{1}, a_{2}, ,a8\cdots, a_{8}. Then
a1a2+a2a3+a3a4+a4a5+a5a6+a6a7+a7a8+a8a1 \begin{array}{l} \left|a_{1}-a_{2}\right|+\left|a_{2}-a_{3}\right|+\left|a_{3}-a_{4}\right|+\left|a_{4}-a_{5}\right|^{\prime}+ \\ \left|a_{5}-a_{6}\right|+\left|a_{6}-a_{7}\right|+\left|a_{7}-a_{8}\right|+\left|a_{8}-a_{1}\right|^{\prime} \end{array}

The maximum value is \qquad

A number or a short expression. Spacing and $ signs are ignored.

Solution

5. 32 .

From the problem, we have
S=a1a2+a2a3+a3a4+a4a5+a5a6+a6a7+a7a8+a8a1. \begin{aligned} S= & \left|a_{1}-a_{2}\right|+\left|a_{2}-a_{3}\right|+\left|a_{3}-a_{4}\right|+ \\ & \left|a_{4}-a_{5}\right|+\left|a_{5}-a_{6}\right|+\left|a_{6}-a_{7}\right|+ \\ & \left|a_{7}-a_{8}\right|+\left|a_{8}-a_{1}\right| . \end{aligned}

Removing the absolute value signs in any term of this sum, we get one positive and one negative natural number. To achieve the maximum possible value of the sum, we need to take the numbers from 1 to 4 as negative and the numbers from 5 to 8 as positive. Thus,
S=2[(8+7+6+5)(4+3+2+1)]=32 For example, 84+47+71+15+52+26+63+38=32. \begin{array}{l} S=2[(8+7+6+5)-(4+3+2+1)]=32 \text {. } \\ \text { For example, }|8-4|+|4-7|+|7-1|+|1-5|+ \\ |5-2|+|2-6|+|6-3|+|3-8| \\ =32 . \end{array}

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: NuminaMath-1.5, licensed Apache-2.0. Statement and solution reproduced as published; topic and difficulty added by this site.