// File: EverybodyHops[P]Permutations/./permutations.hpp
// Function: dic_order<int>::dic_order(std::vector<int, std::allocator<int>>)
dic_order(vector<T> init_per){
        this->ordered_element = init_per;
        sort(this->ordered_element.begin(), this->ordered_element.end());

        //permutation to media number
        vector<int> t;
        int temp;
        for(int i = 0; i < init_per.size() - 1; i++){
            temp = 0;
            for(int j = i + 1; j < init_per.size(); j++){
                if(init_per[i] > init_per[j]){
                    temp += 1;
                }
            }
            t.push_back(temp);
        }
        reverse(t.begin(), t.end());
        this->media_num = new increase_carry(t);

        #ifdef DEBUG
            this->media_num->print_num();
        #endif
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xd0, %rsp
movq %rsi, -0x90(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x98(%rbp)
callq 0x7cf0
movq -0x98(%rbp), %rdi
movq -0x90(%rbp), %rsi
leaq 0xd801(%rip), %rax      # 0x12cd0
movq %rax, (%rdi)
addq $0x10, %rdi
callq 0x7d20
jmp 0x54dd
movq -0x98(%rbp), %rdi
addq $0x10, %rdi
movq %rdi, -0xa0(%rbp)
callq 0x3290
movq -0xa0(%rbp), %rdi
movq %rax, -0x28(%rbp)
callq 0x32c0
movq %rax, -0x30(%rbp)
movq -0x28(%rbp), %rdi
movq -0x30(%rbp), %rsi
callq 0x7f70
jmp 0x5517
leaq -0x48(%rbp), %rdi
callq 0x3130
movl $0x0, -0x50(%rbp)
movq -0x90(%rbp), %rdi
movslq -0x50(%rbp), %rax
movq %rax, -0xa8(%rbp)
callq 0x30f0
movq %rax, %rcx
movq -0xa8(%rbp), %rax
subq $0x1, %rcx
cmpq %rcx, %rax
jae 0x561c
movl $0x0, -0x4c(%rbp)
movl -0x50(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x54(%rbp)
movq -0x90(%rbp), %rdi
movslq -0x54(%rbp), %rax
movq %rax, -0xb0(%rbp)
callq 0x30f0
movq %rax, %rcx
movq -0xb0(%rbp), %rax
cmpq %rcx, %rax
jae 0x55ec
movq -0x90(%rbp), %rdi
movslq -0x50(%rbp), %rsi
callq 0x3110
movq -0x90(%rbp), %rdi
movl (%rax), %eax
movl %eax, -0xb4(%rbp)
movslq -0x54(%rbp), %rsi
callq 0x3110
movq %rax, %rcx
movl -0xb4(%rbp), %eax
cmpl (%rcx), %eax
jle 0x55dc
movl -0x4c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4c(%rbp)
jmp 0x55dc
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x5703
jmp 0x55de
movl -0x54(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x54(%rbp)
jmp 0x5565
leaq -0x48(%rbp), %rdi
leaq -0x4c(%rbp), %rsi
callq 0x3150
jmp 0x55fb
jmp 0x55fd
movl -0x50(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x50(%rbp)
jmp 0x5527
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x56fa
leaq -0x48(%rbp), %rdi
movq %rdi, -0xc0(%rbp)
callq 0x3290
movq -0xc0(%rbp), %rdi
movq %rax, -0x60(%rbp)
callq 0x32c0
movq %rax, -0x68(%rbp)
movq -0x60(%rbp), %rdi
movq -0x68(%rbp), %rsi
callq 0x7fb0
jmp 0x564f
movl $0x30, %edi
callq 0x20f0
movq %rax, -0xc8(%rbp)
jmp 0x5662
movb $0x1, -0x81(%rbp)
leaq -0x80(%rbp), %rdi
leaq -0x48(%rbp), %rsi
callq 0x2f70
jmp 0x5678
movq -0xc8(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0x2cf0
jmp 0x568a
movq -0x98(%rbp), %rax
movq -0xc8(%rbp), %rcx
movb $0x0, -0x81(%rbp)
movq %rcx, 0x8(%rax)
leaq -0x80(%rbp), %rdi
callq 0x3090
leaq -0x48(%rbp), %rdi
callq 0x3090
addq $0xd0, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
jmp 0x56e1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x18(%rbp)
movl %eax, -0x1c(%rbp)
leaq -0x80(%rbp), %rdi
callq 0x3090
testb $0x1, -0x81(%rbp)
jne 0x56ec
jmp 0x56f8
movq -0xc8(%rbp), %rdi
callq 0x20d0
jmp 0x56fa
leaq -0x48(%rbp), %rdi
callq 0x3090
movq -0x98(%rbp), %rdi
callq 0x7970
movq -0x18(%rbp), %rdi
callq 0x21b0
nopl (%rax,%rax)