Push-swap is a very simple and highly effective algorithm. You have at your disposal a list of `int` values, two stacks (`a` and `b`) and a set of instructions.
- **push-swap**, which calculates and displays on the standard output the smallest program using push-swap instruction language that sorts integer arguments received.
- **checker**, which takes integer arguments and reads instructions on the standard output. Once read, checker executes them and displays `OK` if integers are sorted. Otherwise, it will display `KO`.
As said before, you will have two stacks at your disposal. Your goal is to sort the stack `a`, that will contain the `int` values received, in ascending order, using both stacks and a set of instructions.
- You have to write a program named push-swap, which will receive as an argument the stack `a` formatted as a list of integers. The first integer should be at the top of the stack.
- In case of error, you must display `Error` followed by a `\n` on the standard error. Errors are understood as: some arguments are not integers and/or there are duplicates.
- If there are no arguments, the program does not display anything (0 instructions).
- You have to write a program named checker, which will get as an argument the stack `a` formatted as a list of integers. The first argument should be at the top of the stack (be careful about the order). If no argument is given, checker stops and displays nothing.
- Checker will then read instructions on the standard input, each instruction will be followed by `\n`. Once all the instructions have been read, checker will execute them on the stack received as an argument.
- If after executing those instructions, stack `a` is actually sorted and `b` is empty, then checker must display "OK" followed by a `\n` on the standard output. In every other case, checker must display "KO" followed by a `\n` on the standard output.
- In case of error, you must display Error followed by a `\n` on the standard error. Errors include for example: some arguments are not integers, there are duplicates, an instruction do not exist and/or is incorrectly formatted.