Can we sort the array with reverse?

Правка en2, от hasanb, 2016-05-14 23:31:29

The problem is what's the minimum amount of reverse so the array become sorted. I observed in the worst case answer is N-1. But how can I solve the problem?

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский hasanb 2016-05-14 23:31:29 2 Tiny change: 'nswer is N. \nBut ho' -> 'nswer is N-1. \nBut ho'
en1 Английский hasanb 2016-05-13 20:11:42 192 Initial revision (published)