Kanade has an even number n and a permutation b of all of the even numbers in [1,n]
Let a denote an array [1,3,5....n-1] , now you need to find a permutation of [1,n] satisfy both a and b are subsequence of it and minimize the number of inverse pair of it.
输入描述:
The first line has a positive even integer n
The second line has n/2 positive even integers b[i]
输出描述:
Output the number of inverse pair of the permutation you find.