Three Blocks Palindrome

2020 VietMX 0

The only difference between easy and hard versions is constraints. You are given a sequence $a$ consisting of $n$ positive integers. Let’s define a three blocks […]