Problem

Source: China Mathematical Olympiad 2020 Q1

Tags: algebra, maximum value



Let $a_1,a_2,\cdots,a_{41}\in\mathbb{R},$ such that $a_{41}=a_1, \sum_{i=1}^{40}a_i=0,$ and for any $i=1,2,\cdots,40, |a_i-a_{i+1}|\leq 1.$ Determine the greatest possible value of $(1)a_{10}+a_{20}+a_{30}+a_{40};$ $(2)a_{10}\cdot a_{20}+a_{30}\cdot a_{40}.$