PROGRAMMING:Solving inverse order number problem
Let A1, A2,..., an be an permutation of the set {1, 2,..., n}. If $$I < J $$and AI > AJ, then the order pair (AI, AJ) is called a reverse order of the permutation. For example, 2,3,1 has two reverse orders: (3,1) and (2,1). The algorithm is designed to count the number of inverses in a given permutation.
###Input format:
In the first line, the number of elements in the set is n, and in the second line, the number of elements in the set is n.
```in
three
2 3 1
```
###Output format:
The number containing the reverse order.
```out
two
```
answer:If there is no answer, please comment
###Input format:
In the first line, the number of elements in the set is n, and in the second line, the number of elements in the set is n.
```in
three
2 3 1
```
###Output format:
The number containing the reverse order.
```out
two
```
answer:If there is no answer, please comment