MEMO 2015 ekipno problem 3


Kvaliteta:
  Avg: 0.0
Težina:
  Avg: 6.0

There are n students standing in line in positions 1 to n. While the teacher looks away, some students change their positions. When the teacher looks back, they are standing in line again. If a student who was initially in position i is now in position j, we say the student moved for |i - j| steps. Determine the maximal sum of steps of all students that they can achieve.

Source: Srednjoeuropska matematička olimpijada 2015, ekipno natjecanje, problem 3