// File: girdhari9[P]TEXPLORER/cmd_main.cpp
// Function: set_path(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, int)
int set_path(string current_path,int i){
    if(v.size() < 3){
        cout<<v[0]<<": command syntax is not correct 'help' - to find correct syntax.\n";
        return 0;
    }
    if(v[v.size()-1][0] == '~') {
        if(v[i][0] == '~'){
            size_t found = v[i].find_last_of("/\\");
            dest_path = home_path + "/" + v[v.size()-1].substr(2) + "/" + v[i].substr(found+1);
        }
        else{
            size_t found = v[i].find_last_of("/\\");
            if(found != string::npos)
                dest_path = home_path + "/" + v[v.size()-1] + "/" + v[i].substr(found+1);
            else dest_path = home_path + "/" + v[v.size()-1] + "/" + v[i];
        }
    }
    else {
        if(v[i][0] == '~'){
            size_t found = v[i].find_last_of("/\\");
            dest_path = current_path + "/" + v[v.size()-1] + "/" + v[i].substr(found+1);
        }
        size_t found = v[i].find_last_of("/\\");
        if(found != string::npos)
            dest_path = home_path + "/" + v[v.size()-1] + "/" + v[i].substr(found+1);
        else dest_path = home_path + "/" + v[v.size()-1] + "/" + v[i];
    }

    if(v[i][0] == '~') source_path = home_path + "/" + v[i].substr(2);
    else source_path = current_path + "/" + v[i];
    return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x500, %rsp            # imm = 0x500
movq %rdi, -0x490(%rbp)
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
leaq 0xbb58(%rip), %rdi      # 0x188f8
callq 0x8e60
cmpq $0x3, %rax
jae 0xcde5
leaq 0xbb46(%rip), %rdi      # 0x188f8
xorl %eax, %eax
movl %eax, %esi
callq 0x8e80
movq %rax, %rsi
movq 0xb20b(%rip), %rdi      # 0x17fd0
callq 0x3290
movq %rax, %rdi
leaq 0x4443(%rip), %rsi      # 0x11217
callq 0x32d0
movl $0x0, -0x4(%rbp)
jmp 0xda22
leaq 0xbb0c(%rip), %rdi      # 0x188f8
callq 0x8e60
movq %rax, %rsi
subq $0x1, %rsi
leaq 0xbaf9(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x35b0
movsbl (%rax), %eax
cmpl $0x7e, %eax
jne 0xd361
movslq -0x14(%rbp), %rsi
leaq 0xbad1(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x35b0
movsbl (%rax), %eax
cmpl $0x7e, %eax
jne 0xd036
movslq -0x14(%rbp), %rsi
leaq 0xbaa9(%rip), %rdi      # 0x188f8
movq %rdi, -0x4a0(%rbp)
callq 0x8e80
movq %rax, %rdi
leaq 0x41ed(%rip), %rsi      # 0x11052
movq $-0x1, %rdx
movq %rdx, -0x498(%rbp)
callq 0x32b0
movq %rax, -0x20(%rbp)
leaq 0xb895(%rip), %rsi      # 0x18718
leaq 0x4257(%rip), %rdx      # 0x110e1
leaq -0xa0(%rbp), %rdi
callq 0x5490
movq -0x4a0(%rbp), %rdi
callq 0x8e60
movq -0x4a0(%rbp), %rdi
movq %rax, %rsi
decq %rsi
callq 0x8e80
movq -0x498(%rbp), %rcx
movq %rax, %rsi
leaq -0xc0(%rbp), %rdi
movl $0x2, %edx
callq 0x3310
jmp 0xced1
leaq -0x80(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
leaq -0xc0(%rbp), %rdx
callq 0xddf0
jmp 0xceea
leaq 0x41f0(%rip), %rdx      # 0x110e1
leaq -0x60(%rbp), %rdi
leaq -0x80(%rbp), %rsi
callq 0x5440
jmp 0xcf00
movslq -0x14(%rbp), %rsi
leaq 0xb9ed(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rsi
movq -0x20(%rbp), %rdx
incq %rdx
leaq -0xf0(%rbp), %rdi
movq $-0x1, %rcx
callq 0x3310
jmp 0xcf2f
leaq -0x40(%rbp), %rdi
leaq -0x60(%rbp), %rsi
leaq -0xf0(%rbp), %rdx
callq 0xddf0
jmp 0xcf45
leaq 0xbdf4(%rip), %rdi      # 0x18d40
leaq -0x40(%rbp), %rsi
callq 0x33e0
leaq -0x40(%rbp), %rdi
callq 0x35c8
leaq -0xf0(%rbp), %rdi
callq 0x35c8
leaq -0x60(%rbp), %rdi
callq 0x35c8
leaq -0x80(%rbp), %rdi
callq 0x35c8
leaq -0xc0(%rbp), %rdi
callq 0x35c8
leaq -0xa0(%rbp), %rdi
callq 0x35c8
jmp 0xd35c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd025
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd019
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd010
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd007
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
leaq -0xf0(%rbp), %rdi
callq 0x35c8
leaq -0x60(%rbp), %rdi
callq 0x35c8
leaq -0x80(%rbp), %rdi
callq 0x35c8
leaq -0xc0(%rbp), %rdi
callq 0x35c8
leaq -0xa0(%rbp), %rdi
callq 0x35c8
jmp 0xda2e
movslq -0x14(%rbp), %rsi
leaq 0xb8b7(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rdi
leaq 0x4002(%rip), %rsi      # 0x11052
movq $-0x1, %rdx
callq 0x32b0
movq %rax, -0xf8(%rbp)
cmpq $-0x1, -0xf8(%rbp)
je 0xd210
leaq 0xb6a0(%rip), %rsi      # 0x18718
leaq 0x4062(%rip), %rdx      # 0x110e1
leaq -0x178(%rbp), %rdi
movq %rdi, -0x4a8(%rbp)
callq 0x5490
leaq 0xb85f(%rip), %rdi      # 0x188f8
movq %rdi, -0x4b0(%rbp)
callq 0x8e60
movq -0x4b0(%rbp), %rdi
movq %rax, %rsi
decq %rsi
callq 0x8e80
movq -0x4a8(%rbp), %rsi
movq %rax, %rdx
leaq -0x158(%rbp), %rdi
callq 0x5370
jmp 0xd0cf
leaq 0x400b(%rip), %rdx      # 0x110e1
leaq -0x138(%rbp), %rdi
leaq -0x158(%rbp), %rsi
callq 0x5440
jmp 0xd0eb
movslq -0x14(%rbp), %rsi
leaq 0xb802(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rsi
movq -0xf8(%rbp), %rdx
incq %rdx
leaq -0x198(%rbp), %rdi
movq $-0x1, %rcx
callq 0x3310
jmp 0xd11d
leaq -0x118(%rbp), %rdi
leaq -0x138(%rbp), %rsi
leaq -0x198(%rbp), %rdx
callq 0xddf0
jmp 0xd139
leaq 0xbc00(%rip), %rdi      # 0x18d40
leaq -0x118(%rbp), %rsi
callq 0x33e0
leaq -0x118(%rbp), %rdi
callq 0x35c8
leaq -0x198(%rbp), %rdi
callq 0x35c8
leaq -0x138(%rbp), %rdi
callq 0x35c8
leaq -0x158(%rbp), %rdi
callq 0x35c8
leaq -0x178(%rbp), %rdi
callq 0x35c8
jmp 0xd35a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd1ff
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd1f3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd1e7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
leaq -0x198(%rbp), %rdi
callq 0x35c8
leaq -0x138(%rbp), %rdi
callq 0x35c8
leaq -0x158(%rbp), %rdi
callq 0x35c8
leaq -0x178(%rbp), %rdi
callq 0x35c8
jmp 0xda2e
leaq 0xb501(%rip), %rsi      # 0x18718
leaq 0x3ec3(%rip), %rdx      # 0x110e1
leaq -0x218(%rbp), %rdi
movq %rdi, -0x4b8(%rbp)
callq 0x5490
leaq 0xb6c0(%rip), %rdi      # 0x188f8
movq %rdi, -0x4c0(%rbp)
callq 0x8e60
movq -0x4c0(%rbp), %rdi
movq %rax, %rsi
decq %rsi
callq 0x8e80
movq -0x4b8(%rbp), %rsi
movq %rax, %rdx
leaq -0x1f8(%rbp), %rdi
callq 0x5370
jmp 0xd26e
leaq 0x3e6c(%rip), %rdx      # 0x110e1
leaq -0x1d8(%rbp), %rdi
leaq -0x1f8(%rbp), %rsi
callq 0x5440
jmp 0xd28a
movslq -0x14(%rbp), %rsi
leaq 0xb663(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rdx
leaq -0x1b8(%rbp), %rdi
leaq -0x1d8(%rbp), %rsi
callq 0x5370
jmp 0xd2b2
leaq 0xba87(%rip), %rdi      # 0x18d40
leaq -0x1b8(%rbp), %rsi
callq 0x33e0
leaq -0x1b8(%rbp), %rdi
callq 0x35c8
leaq -0x1d8(%rbp), %rdi
callq 0x35c8
leaq -0x1f8(%rbp), %rdi
callq 0x35c8
leaq -0x218(%rbp), %rdi
callq 0x35c8
jmp 0xd35a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd349
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd33d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
leaq -0x1d8(%rbp), %rdi
callq 0x35c8
leaq -0x1f8(%rbp), %rdi
callq 0x35c8
leaq -0x218(%rbp), %rdi
callq 0x35c8
jmp 0xda2e
jmp 0xd35c
jmp 0xd87b
movslq -0x14(%rbp), %rsi
leaq 0xb58c(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x35b0
movsbl (%rax), %eax
cmpl $0x7e, %eax
jne 0xd555
movslq -0x14(%rbp), %rsi
leaq 0xb564(%rip), %rdi      # 0x188f8
movq %rdi, -0x4d0(%rbp)
callq 0x8e80
movq %rax, %rdi
leaq 0x3ca8(%rip), %rsi      # 0x11052
movq $-0x1, %rdx
callq 0x32b0
movq -0x490(%rbp), %rsi
movq %rax, -0x220(%rbp)
leaq 0x3d16(%rip), %rdx      # 0x110e1
leaq -0x2a0(%rbp), %rdi
movq %rdi, -0x4c8(%rbp)
callq 0x5490
movq -0x4d0(%rbp), %rdi
callq 0x8e60
movq -0x4d0(%rbp), %rdi
movq %rax, %rsi
decq %rsi
callq 0x8e80
movq -0x4c8(%rbp), %rsi
movq %rax, %rdx
leaq -0x280(%rbp), %rdi
callq 0x5370
jmp 0xd414
leaq 0x3cc6(%rip), %rdx      # 0x110e1
leaq -0x260(%rbp), %rdi
leaq -0x280(%rbp), %rsi
callq 0x5440
jmp 0xd430
movslq -0x14(%rbp), %rsi
leaq 0xb4bd(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rsi
movq -0x220(%rbp), %rdx
incq %rdx
leaq -0x2c0(%rbp), %rdi
movq $-0x1, %rcx
callq 0x3310
jmp 0xd462
leaq -0x240(%rbp), %rdi
leaq -0x260(%rbp), %rsi
leaq -0x2c0(%rbp), %rdx
callq 0xddf0
jmp 0xd47e
leaq 0xb8bb(%rip), %rdi      # 0x18d40
leaq -0x240(%rbp), %rsi
callq 0x33e0
leaq -0x240(%rbp), %rdi
callq 0x35c8
leaq -0x2c0(%rbp), %rdi
callq 0x35c8
leaq -0x260(%rbp), %rdi
callq 0x35c8
leaq -0x280(%rbp), %rdi
callq 0x35c8
leaq -0x2a0(%rbp), %rdi
callq 0x35c8
jmp 0xd555
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd544
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd538
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd52c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
leaq -0x2c0(%rbp), %rdi
callq 0x35c8
leaq -0x260(%rbp), %rdi
callq 0x35c8
leaq -0x280(%rbp), %rdi
callq 0x35c8
leaq -0x2a0(%rbp), %rdi
callq 0x35c8
jmp 0xda2e
movslq -0x14(%rbp), %rsi
leaq 0xb398(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rdi
leaq 0x3ae3(%rip), %rsi      # 0x11052
movq $-0x1, %rdx
callq 0x32b0
movq %rax, -0x2c8(%rbp)
cmpq $-0x1, -0x2c8(%rbp)
je 0xd72f
leaq 0xb181(%rip), %rsi      # 0x18718
leaq 0x3b43(%rip), %rdx      # 0x110e1
leaq -0x348(%rbp), %rdi
movq %rdi, -0x4d8(%rbp)
callq 0x5490
leaq 0xb340(%rip), %rdi      # 0x188f8
movq %rdi, -0x4e0(%rbp)
callq 0x8e60
movq -0x4e0(%rbp), %rdi
movq %rax, %rsi
decq %rsi
callq 0x8e80
movq -0x4d8(%rbp), %rsi
movq %rax, %rdx
leaq -0x328(%rbp), %rdi
callq 0x5370
jmp 0xd5ee
leaq 0x3aec(%rip), %rdx      # 0x110e1
leaq -0x308(%rbp), %rdi
leaq -0x328(%rbp), %rsi
callq 0x5440
jmp 0xd60a
movslq -0x14(%rbp), %rsi
leaq 0xb2e3(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rsi
movq -0x2c8(%rbp), %rdx
incq %rdx
leaq -0x368(%rbp), %rdi
movq $-0x1, %rcx
callq 0x3310
jmp 0xd63c
leaq -0x2e8(%rbp), %rdi
leaq -0x308(%rbp), %rsi
leaq -0x368(%rbp), %rdx
callq 0xddf0
jmp 0xd658
leaq 0xb6e1(%rip), %rdi      # 0x18d40
leaq -0x2e8(%rbp), %rsi
callq 0x33e0
leaq -0x2e8(%rbp), %rdi
callq 0x35c8
leaq -0x368(%rbp), %rdi
callq 0x35c8
leaq -0x308(%rbp), %rdi
callq 0x35c8
leaq -0x328(%rbp), %rdi
callq 0x35c8
leaq -0x348(%rbp), %rdi
callq 0x35c8
jmp 0xd879
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd71e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd712
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd706
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
leaq -0x368(%rbp), %rdi
callq 0x35c8
leaq -0x308(%rbp), %rdi
callq 0x35c8
leaq -0x328(%rbp), %rdi
callq 0x35c8
leaq -0x348(%rbp), %rdi
callq 0x35c8
jmp 0xda2e
leaq 0xafe2(%rip), %rsi      # 0x18718
leaq 0x39a4(%rip), %rdx      # 0x110e1
leaq -0x3e8(%rbp), %rdi
movq %rdi, -0x4e8(%rbp)
callq 0x5490
leaq 0xb1a1(%rip), %rdi      # 0x188f8
movq %rdi, -0x4f0(%rbp)
callq 0x8e60
movq -0x4f0(%rbp), %rdi
movq %rax, %rsi
decq %rsi
callq 0x8e80
movq -0x4e8(%rbp), %rsi
movq %rax, %rdx
leaq -0x3c8(%rbp), %rdi
callq 0x5370
jmp 0xd78d
leaq 0x394d(%rip), %rdx      # 0x110e1
leaq -0x3a8(%rbp), %rdi
leaq -0x3c8(%rbp), %rsi
callq 0x5440
jmp 0xd7a9
movslq -0x14(%rbp), %rsi
leaq 0xb144(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rdx
leaq -0x388(%rbp), %rdi
leaq -0x3a8(%rbp), %rsi
callq 0x5370
jmp 0xd7d1
leaq 0xb568(%rip), %rdi      # 0x18d40
leaq -0x388(%rbp), %rsi
callq 0x33e0
leaq -0x388(%rbp), %rdi
callq 0x35c8
leaq -0x3a8(%rbp), %rdi
callq 0x35c8
leaq -0x3c8(%rbp), %rdi
callq 0x35c8
leaq -0x3e8(%rbp), %rdi
callq 0x35c8
jmp 0xd879
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd868
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd85c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
leaq -0x3a8(%rbp), %rdi
callq 0x35c8
leaq -0x3c8(%rbp), %rdi
callq 0x35c8
leaq -0x3e8(%rbp), %rdi
callq 0x35c8
jmp 0xda2e
jmp 0xd87b
movslq -0x14(%rbp), %rsi
leaq 0xb072(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x35b0
movsbl (%rax), %eax
cmpl $0x7e, %eax
jne 0xd985
leaq 0xae6e(%rip), %rsi      # 0x18718
leaq 0x3830(%rip), %rdx      # 0x110e1
leaq -0x428(%rbp), %rdi
callq 0x5490
movslq -0x14(%rbp), %rsi
leaq 0xb030(%rip), %rdi      # 0x188f8
callq 0x8e80
movq %rax, %rsi
leaq -0x448(%rbp), %rdi
movl $0x2, %edx
movq $-0x1, %rcx
callq 0x3310
jmp 0xd8ea
leaq -0x408(%rbp), %rdi
leaq -0x428(%rbp), %rsi
leaq -0x448(%rbp), %rdx
callq 0xddf0
jmp 0xd906
leaq 0xb453(%rip), %rdi      # 0x18d60
leaq -0x408(%rbp), %rsi
callq 0x33e0
leaq -0x408(%rbp), %rdi
callq 0x35c8
leaq -0x448(%rbp), %rdi
callq 0x35c8
leaq -0x428(%rbp), %rdi
callq 0x35c8
jmp 0xda1b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
jmp 0xd974
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
leaq -0x448(%rbp), %rdi
callq 0x35c8
leaq -0x428(%rbp), %rdi
callq 0x35c8
jmp 0xda2e
movq -0x490(%rbp), %rsi
leaq 0x374e(%rip), %rdx      # 0x110e1
leaq -0x488(%rbp), %rdi
movq %rdi, -0x4f8(%rbp)
callq 0x5490
movslq -0x14(%rbp), %rsi
leaq 0xaf47(%rip), %rdi      # 0x188f8
callq 0x8e80
movq -0x4f8(%rbp), %rsi
movq %rax, %rdx
leaq -0x468(%rbp), %rdi
callq 0x5370
jmp 0xd9ce
leaq 0xb38b(%rip), %rdi      # 0x18d60
leaq -0x468(%rbp), %rsi
callq 0x33e0
leaq -0x468(%rbp), %rdi
callq 0x35c8
leaq -0x488(%rbp), %rdi
callq 0x35c8
jmp 0xda1b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xc8(%rbp)
movl %eax, -0xcc(%rbp)
leaq -0x488(%rbp), %rdi
callq 0x35c8
jmp 0xda2e
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x500, %rsp            # imm = 0x500
popq %rbp
retq
movq -0xc8(%rbp), %rdi
callq 0x3530
nopw (%rax,%rax)