Getting TLE in Max Query 1

my code https://ide.codingblocks.com/s/36141
ques https://hack.codingblocks.com/contests/c/547/311

how can we use lazy propagation to optimize it as there are no updates given in the question

You need to use Binary Indexed Tree