// File: bothaynahazem[P]AsuMathLabG13/main.cpp
// Function: concatenate(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
string concatenate (string s){

        string z =s;
        addcomma(z);
        Matrix matarr[2];
        int commapos,closedbracket,openedbracket;
        string tempconstruct;
        while (z.find(',') != string::npos)
        {
        commapos = z.find(',', 0);
        openedbracket=z.find_last_of('[',commapos);
        closedbracket=z.find_last_of(']',commapos);
        tempconstruct=z.substr(openedbracket, closedbracket - openedbracket+1);
        z.replace(openedbracket, closedbracket - openedbracket+1," ");
        matarr[0]=Matrix(tempconstruct);
        commapos = z.find(',', 0);
        openedbracket=z.find_first_of('[',commapos);
        closedbracket=z.find_first_of(']',commapos);
        tempconstruct=z.substr(openedbracket, closedbracket - openedbracket+1);
        z.replace(openedbracket, closedbracket - openedbracket+1," ");
        matarr[1]=Matrix(tempconstruct);
        matarr[0].addColumn(matarr[1]);
        string y = matarr[0].getAltString();
        z.replace(commapos,1,y);
        }
        return z;
        }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x2d0, %rsp            # imm = 0x2D0
movq %rdi, -0x258(%rbp)
movq %rdi, %rax
movq %rax, -0x260(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movb $0x0, -0x11(%rbp)
callq 0x3180
movq -0x258(%rbp), %rdi
callq 0x3ab0
jmp 0x3beb
leaq -0xa0(%rbp), %rax
movq %rax, -0x278(%rbp)
movq %rax, %rcx
addq $0x70, %rcx
movq %rcx, -0x270(%rbp)
movq %rax, -0x268(%rbp)
movq -0x268(%rbp), %rdi
movq %rdi, -0x280(%rbp)
callq 0xe5d0
jmp 0x3c23
movq -0x270(%rbp), %rcx
movq -0x280(%rbp), %rax
addq $0x38, %rax
cmpq %rcx, %rax
movq %rax, -0x268(%rbp)
jne 0x3c0e
leaq -0xd0(%rbp), %rdi
callq 0x3510
movq -0x258(%rbp), %rdi
movl $0x2c, %esi
xorl %eax, %eax
movl %eax, %edx
callq 0x34d0
cmpq $-0x1, %rax
je 0x403a
movq -0x258(%rbp), %rdi
xorl %eax, %eax
movl %eax, %edx
movl $0x2c, %esi
callq 0x34d0
movq -0x258(%rbp), %rdi
movl %eax, -0xa4(%rbp)
movslq -0xa4(%rbp), %rdx
movl $0x5b, %esi
callq 0x36c0
movq -0x258(%rbp), %rdi
movl %eax, -0xac(%rbp)
movslq -0xa4(%rbp), %rdx
movl $0x5d, %esi
callq 0x36c0
movq -0x258(%rbp), %rsi
movl %eax, -0xa8(%rbp)
movslq -0xac(%rbp), %rdx
movl %edx, %ecx
movl -0xa8(%rbp), %eax
subl %ecx, %eax
incl %eax
movslq %eax, %rcx
leaq -0xf0(%rbp), %rdi
callq 0x33e0
jmp 0x3cee
leaq -0xd0(%rbp), %rdi
leaq -0xf0(%rbp), %rsi
movq %rsi, -0x288(%rbp)
callq 0x3450
movq -0x288(%rbp), %rdi
callq 0x3270
movq -0x258(%rbp), %rdi
movslq -0xac(%rbp), %rsi
movl %esi, %ecx
movl -0xa8(%rbp), %eax
subl %ecx, %eax
incl %eax
movslq %eax, %rdx
leaq 0x175e0(%rip), %rcx     # 0x1b318
callq 0x3260
jmp 0x3d3f
leaq -0x180(%rbp), %rdi
leaq -0xd0(%rbp), %rsi
callq 0x3180
jmp 0x3d54
leaq -0x160(%rbp), %rdi
leaq -0x180(%rbp), %rsi
callq 0xf070
jmp 0x3d69
leaq -0x128(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
leaq -0x160(%rbp), %rdx
callq 0x10e80
jmp 0x3d85
leaq -0x128(%rbp), %rdi
callq 0xe650
leaq -0x160(%rbp), %rdi
callq 0xe650
leaq -0x180(%rbp), %rdi
callq 0x3270
movq -0x258(%rbp), %rdi
xorl %eax, %eax
movl %eax, %edx
movl $0x2c, %esi
callq 0x34d0
movq -0x258(%rbp), %rdi
movl %eax, -0xa4(%rbp)
movslq -0xa4(%rbp), %rdx
movl $0x5b, %esi
callq 0x32a0
movq -0x258(%rbp), %rdi
movl %eax, -0xac(%rbp)
movslq -0xa4(%rbp), %rdx
movl $0x5d, %esi
callq 0x32a0
movq -0x258(%rbp), %rsi
movl %eax, -0xa8(%rbp)
movslq -0xac(%rbp), %rdx
movl %edx, %ecx
movl -0xa8(%rbp), %eax
subl %ecx, %eax
incl %eax
movslq %eax, %rcx
leaq -0x1a0(%rbp), %rdi
callq 0x33e0
jmp 0x3e2b
leaq -0xd0(%rbp), %rdi
leaq -0x1a0(%rbp), %rsi
movq %rsi, -0x290(%rbp)
callq 0x3450
movq -0x290(%rbp), %rdi
callq 0x3270
movq -0x258(%rbp), %rdi
movslq -0xac(%rbp), %rsi
movl %esi, %ecx
movl -0xa8(%rbp), %eax
subl %ecx, %eax
incl %eax
movslq %eax, %rdx
leaq 0x174a3(%rip), %rcx     # 0x1b318
callq 0x3260
jmp 0x3e7c
leaq -0x230(%rbp), %rdi
leaq -0xd0(%rbp), %rsi
callq 0x3180
jmp 0x3e91
leaq -0x210(%rbp), %rdi
leaq -0x230(%rbp), %rsi
callq 0xf070
jmp 0x3ea6
leaq -0x68(%rbp), %rsi
leaq -0x1d8(%rbp), %rdi
leaq -0x210(%rbp), %rdx
callq 0x10e80
jmp 0x3ebf
leaq -0x1d8(%rbp), %rdi
callq 0xe650
leaq -0x210(%rbp), %rdi
callq 0xe650
leaq -0x230(%rbp), %rdi
callq 0x3270
leaq -0x68(%rbp), %rsi
leaq -0xa0(%rbp), %rdi
callq 0xff30
jmp 0x3ef5
leaq -0x250(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
callq 0x10af0
jmp 0x3f0a
movq -0x258(%rbp), %rdi
movslq -0xa4(%rbp), %rsi
movl $0x1, %edx
leaq -0x250(%rbp), %rcx
callq 0x3150
jmp 0x3f2b
leaq -0x250(%rbp), %rdi
callq 0x3270
jmp 0x3c4d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
jmp 0x4114
movq -0x278(%rbp), %rcx
movq %rax, %rsi
movq -0x280(%rbp), %rax
movq %rsi, -0x20(%rbp)
movl %edx, -0x24(%rbp)
cmpq %rax, %rcx
movq %rax, -0x298(%rbp)
je 0x3fa2
movq -0x298(%rbp), %rdi
addq $-0x38, %rdi
movq %rdi, -0x2a0(%rbp)
callq 0xe650
movq -0x278(%rbp), %rcx
movq -0x2a0(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x298(%rbp)
jne 0x3f71
jmp 0x4114
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
jmp 0x4065
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
jmp 0x3fde
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x160(%rbp), %rdi
callq 0xe650
leaq -0x180(%rbp), %rdi
callq 0x3270
jmp 0x4065
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
jmp 0x4012
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x210(%rbp), %rdi
callq 0xe650
leaq -0x230(%rbp), %rdi
callq 0x3270
jmp 0x4065
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x250(%rbp), %rdi
callq 0x3270
jmp 0x4065
movb $0x1, -0x11(%rbp)
leaq -0xd0(%rbp), %rdi
callq 0x3270
leaq -0xa0(%rbp), %rax
movq %rax, -0x2b0(%rbp)
addq $0x70, %rax
movq %rax, -0x2a8(%rbp)
jmp 0x408c
leaq -0xd0(%rbp), %rdi
callq 0x3270
leaq -0xa0(%rbp), %rax
movq %rax, -0x2c0(%rbp)
addq $0x70, %rax
movq %rax, -0x2b8(%rbp)
jmp 0x40c5
movq -0x2a8(%rbp), %rdi
addq $-0x38, %rdi
movq %rdi, -0x2c8(%rbp)
callq 0xe650
movq -0x2b0(%rbp), %rcx
movq -0x2c8(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x2a8(%rbp)
jne 0x408c
testb $0x1, -0x11(%rbp)
jne 0x4104
jmp 0x40f8
movq -0x2b8(%rbp), %rdi
addq $-0x38, %rdi
movq %rdi, -0x2d0(%rbp)
callq 0xe650
movq -0x2c0(%rbp), %rcx
movq -0x2d0(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x2b8(%rbp)
jne 0x40c5
jmp 0x4114
movq -0x258(%rbp), %rdi
callq 0x3270
movq -0x260(%rbp), %rax
addq $0x2d0, %rsp            # imm = 0x2D0
popq %rbp
retq
movq -0x258(%rbp), %rdi
callq 0x3270
movq -0x20(%rbp), %rdi
callq 0x3630
nopl (%rax)