\sum x_k -\sum |x_k| is divisible by 4 , if (-1)^{x_k} x_{k-1}x_{k+1} >0
Source: 1982 Polish MO Finals p5
February 25, 2020
divisibleSequenceSum
Problem Statement
Integers x0,x1,...,xn−1,xn=x0,xn+1=x1 satisfy the inequality (−1)xkxk−1xk+1>0 for k=1,2,...,n. Prove that the difference ∑k=0n−1xk−∑k=0n−1∣xk∣ is divisible by 4.