How to solve sorting problem with different segment in an array

Правка en1, от daihan, 2016-06-14 13:17:01

Supppose somenone give me an array up to 10^6 elements . Then gave some quiries up to 3000 , quries will like that from I index to J index sort in descending , or Ascending order . If 1 ascending , if 2 descending . There has a problem like that -> Report . But i want not from 0 index i want from any I to J index . After quiry how will look the array ? Print the array .

How i can solve this problem without using STL sort . In efficient way .

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский daihan 2016-06-14 13:18:13 115
en1 Английский daihan 2016-06-14 13:17:01 562 Initial revision (published)