// File: /workspace/github_cpp_makefile_star2_O2/DCTewi[P]Truthtable-Calculator/functions.cpp
// Function: prepareWork(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&)
void prepareWork(std::string &s)
{
    size_t plc = 0;
    while ((plc = s.find("&&")) != std::string::npos)
    {
        s = s.replace(plc, 2, "&");
    }
    while ((plc = s.find("||")) != std::string::npos)
    {
        s = s.replace(plc, 2, "|");
    }
    while ((plc = s.find("->")) != std::string::npos)
    {
        s = s.replace(plc, 2, "-");
    }
    while ((plc = s.find("==")) != std::string::npos)
    {
        s = s.replace(plc, 2, "=");
    }

    for (int i = 1; i < static_cast<int>(s.size()); i++)
    {
        while (s[i] == '!' && s[i - 1] == '!')
        {
            s = s.substr(0, i - 1) + s.substr(std::min(i + 1, static_cast<int>(s.size())));
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rdi, %rbx
leaq 0x2be8(%rip), %r14      # 0x5024
leaq 0x2be2(%rip), %r15      # 0x5025
pushq $0x2
popq %r12
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x2260
cmpq $-0x1, %rax
je 0x2478
movq %rbx, %rdi
movq %rax, %rsi
movq %r12, %rdx
movq %r15, %rcx
callq 0x20d0
movq %rbx, %rdi
movq %rax, %rsi
callq 0x20c0
jmp 0x2447
leaq 0x2ba8(%rip), %r14      # 0x5027
leaq 0x2ba2(%rip), %r15      # 0x5028
pushq $0x2
popq %r12
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x2260
cmpq $-0x1, %rax
je 0x24bb
movq %rbx, %rdi
movq %rax, %rsi
movq %r12, %rdx
movq %r15, %rcx
callq 0x20d0
movq %rbx, %rdi
movq %rax, %rsi
callq 0x20c0
jmp 0x248a
leaq 0x2b68(%rip), %r14      # 0x502a
leaq 0x2b64(%rip), %r15      # 0x502d
pushq $0x2
popq %r12
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x2260
cmpq $-0x1, %rax
je 0x24fe
movq %rbx, %rdi
movq %rax, %rsi
movq %r12, %rdx
movq %r15, %rcx
callq 0x20d0
movq %rbx, %rdi
movq %rax, %rsi
callq 0x20c0
jmp 0x24cd
leaq 0x2b2a(%rip), %r14      # 0x502f
leaq 0x2b24(%rip), %r15      # 0x5030
pushq $0x2
popq %r12
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x2260
cmpq $-0x1, %rax
je 0x2541
movq %rbx, %rdi
movq %rax, %rsi
movq %r12, %rdx
movq %r15, %rcx
callq 0x20d0
movq %rbx, %rdi
movq %rax, %rsi
callq 0x20c0
jmp 0x2510
pushq $0x1
popq %r14
movslq 0x8(%rbx), %rax
cmpq %rax, %r14
jge 0x25ec
leaq -0x1(%r14), %rcx
leaq 0x1(%r14), %rax
movq %rax, (%rsp)
movq (%rbx), %rax
cmpb $0x21, (%rax,%r14)
jne 0x25e3
cmpb $0x21, (%rax,%rcx)
leaq 0x28(%rsp), %r15
jne 0x25e3
movq %r15, %rdi
movq %rbx, %rsi
xorl %edx, %edx
movq %rcx, %r12
callq 0x2160
movl 0x8(%rbx), %eax
movq (%rsp), %rcx
cmpl %eax, %ecx
cmovll %ecx, %eax
movslq %eax, %rdx
leaq 0x8(%rsp), %r13
movq %r13, %rdi
movq %rbx, %rsi
pushq $-0x1
popq %rcx
callq 0x2160
leaq 0x48(%rsp), %rbp
movq %rbp, %rdi
movq %r15, %rsi
movq %r13, %rdx
callq 0x3733
movq %rbx, %rdi
movq %rbp, %rsi
callq 0x2190
movq %rbp, %rdi
callq 0x2080
movq %r13, %rdi
callq 0x2080
movq %r15, %rdi
callq 0x2080
movq %r12, %rcx
jmp 0x255e
movq (%rsp), %r14
jmp 0x2545
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x2080
jmp 0x260d
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x2080
movq %rbx, %rdi
callq 0x2240