What the need of this

why anyone want to count those inversion ?

From Algorithms regard, inversion count using divide and conquer is way faster (O(NlogN)) as compared to brute force technique (O(N^2)). Coming to your point it’s not always that whatever you study in algorithms is always useful (atleast to you!), you should look for techniques or tricks to optimize current best solution as this is surely your job. Now for applications, one application is numerical similarity measurement between two ranked list which is used for collaborative filtering. You can read more on wiki more about it.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.