Lab 3.1.1 sort and count

Lab 3.1.1 sort and count

You cannot submit for this problem because the homework's deadline is due.

Description

Use python3 to implement sort and count algorithm.

Submission Format

Submit a tar or zip file including a script named sortcount.py.

IO

Input

A line of numbers, separated by single space.

Output

Two lines.
The first line is the count of inversions.
The second line is the sorted results.

Sample IO

input

3 4 2 1

output

5
[1, 2, 3, 4]

lab3

Not Claimed
Status
Finished
Problems
3
Open Since
2020-09-28 00:00
DDL
2020-10-12 23:59
Extension
72.0 hour(s)