2. Benchmark solution#

The solution is analytical