Another Update-Query Problem

You will be given an array A of length N and you will have to pe...