How to solve this?

Правка en1, от pH7, 2020-07-06 00:03:12

Hi all! I was wondering about solution if in Spoj HORRIBLE we are required to get range multiplication instead of range sum. So basically how can we solve below problem ?

Given an array of N elements handle below two type of range queries. Update L R v : Add v to each element in range [L, R] Query L R : Get multiplication of each element in range [L, R]

I am out of ideas. Please help!

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский pH7 2020-07-06 00:05:38 12
en1 Английский pH7 2020-07-06 00:03:12 456 Initial revision (published)