updated rmq
added segment tree with lazy propagation