// File: chrischute[P]are-you-the-one/src/ayto.cpp
// Function: AreYouTheOneSettings::initializeFromArgs(int, char**)
bool AreYouTheOneSettings::initializeFromArgs(int argc, char** argv) {
    for (int i = 1; i < argc; ++i) {
        if (strncmp(argv[i], "-a", 3) == 0) {
            this->_isAllPermutationsMode = true;
        } else if (strncmp(argv[i], "-f", 3) == 0) {
            this->_isReadFromFileMode = true;
            if (++i == argc) {
                return false;
            }
            this->_fileToRead = argv[i];
        } else if (strncmp(argv[i], "-i", 3) == 0) {
            this->_isInteractiveMode = true;
        } else if (strncmp(argv[i], "-v", 3) == 0) {
            this->_isVerboseMode = true;
        } else if (strncmp(argv[i], "-n", 3) == 0) {
            this->_isPrintNumbersMode = true;
        } else {
            return false;
        }
    }

    // Dictionaries for printing to the console. Males map char -> name
    // because the PerfectMatching string is a permutation of their names.
    if (!this->_isPrintNumbersMode) {
        this->_femaleNames = new map<int, string>{
                {0, "Alyssa"},
                {1, "Camille"},
                {2, "Emma"},
                {3, "Francesca"},
                {4, "Julia"},
                {5, "Kaylen"},
                {6, "Mikala"},
                {7, "Nicole"},
                {8, "Tori"},
                {9, "Victoria"}
        };

        this->_maleNames = new map<char, string>{
                {'0', "Asaf"},
                {'1', "Cam"},
                {'2', "Cameron"},
                {'3', "Giovanni"},
                {'4', "John"},
                {'5', "Morgan"},
                {'6', "Prosper"},
                {'7', "Sam"},
                {'8', "Stephen"},
                {'9', "Tyler"}
        };
    }

    return true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x470, %rsp            # imm = 0x470
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x3d0(%rbp)
movl $0x1, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl -0x14(%rbp), %eax
jge 0x3d35
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
leaq 0x10552(%rip), %rsi     # 0x14159
movl $0x3, %edx
callq 0x3130
cmpl $0x0, %eax
jne 0x3c26
movq -0x3d0(%rbp), %rax
movb $0x1, 0x20(%rax)
jmp 0x3d25
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
leaq 0x10523(%rip), %rsi     # 0x1415c
movl $0x3, %edx
callq 0x3130
cmpl $0x0, %eax
jne 0x3c87
movq -0x3d0(%rbp), %rax
movb $0x1, 0x23(%rax)
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
cmpl -0x14(%rbp), %eax
jne 0x3c6a
movb $0x0, -0x1(%rbp)
jmp 0x4439
movq -0x3d0(%rbp), %rdi
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rsi
callq 0x3410
jmp 0x3d23
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
leaq 0x104c5(%rip), %rsi     # 0x1415f
movl $0x3, %edx
callq 0x3130
cmpl $0x0, %eax
jne 0x3cb6
movq -0x3d0(%rbp), %rax
movb $0x1, 0x21(%rax)
jmp 0x3d21
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
leaq 0x10499(%rip), %rsi     # 0x14162
movl $0x3, %edx
callq 0x3130
cmpl $0x0, %eax
jne 0x3ce5
movq -0x3d0(%rbp), %rax
movb $0x1, 0x24(%rax)
jmp 0x3d1f
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
leaq 0x1046d(%rip), %rsi     # 0x14165
movl $0x3, %edx
callq 0x3130
cmpl $0x0, %eax
jne 0x3d14
movq -0x3d0(%rbp), %rax
movb $0x1, 0x22(%rax)
jmp 0x3d1d
movb $0x0, -0x1(%rbp)
jmp 0x4439
jmp 0x3d1f
jmp 0x3d21
jmp 0x3d23
jmp 0x3d25
jmp 0x3d27
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x3be8
movq -0x3d0(%rbp), %rax
testb $0x1, 0x22(%rax)
jne 0x4435
movl $0x30, %edi
callq 0x32f0
movq %rax, -0x3d8(%rbp)
movb $0x1, -0x20b(%rbp)
leaq -0x1c8(%rbp), %rdi
movq %rdi, -0x1d0(%rbp)
movl $0x0, -0x1d4(%rbp)
leaq 0x103eb(%rip), %rdx     # 0x14168
leaq -0x1d4(%rbp), %rsi
callq 0x70b0
jmp 0x3d8b
leaq -0x1a0(%rbp), %rdi
movq %rdi, -0x1d0(%rbp)
movl $0x1, -0x1e8(%rbp)
leaq 0x103c5(%rip), %rdx     # 0x1416f
leaq -0x1e8(%rbp), %rsi
callq 0x7130
jmp 0x3db8
leaq -0x178(%rbp), %rdi
movq %rdi, -0x1d0(%rbp)
movl $0x2, -0x1ec(%rbp)
leaq 0x103a0(%rip), %rdx     # 0x14177
leaq -0x1ec(%rbp), %rsi
callq 0x71b0
jmp 0x3de5
leaq -0x150(%rbp), %rdi
movq %rdi, -0x1d0(%rbp)
movl $0x3, -0x1f0(%rbp)
leaq 0x10378(%rip), %rdx     # 0x1417c
leaq -0x1f0(%rbp), %rsi
callq 0x7230
jmp 0x3e12
leaq -0x128(%rbp), %rdi
movq %rdi, -0x1d0(%rbp)
movl $0x4, -0x1f4(%rbp)
leaq 0x10355(%rip), %rdx     # 0x14186
leaq -0x1f4(%rbp), %rsi
callq 0x72b0
jmp 0x3e3f
leaq -0x100(%rbp), %rdi
movq %rdi, -0x1d0(%rbp)
movl $0x5, -0x1f8(%rbp)
leaq 0x1032e(%rip), %rdx     # 0x1418c
leaq -0x1f8(%rbp), %rsi
callq 0x70b0
jmp 0x3e6c
leaq -0xd8(%rbp), %rdi
movq %rdi, -0x1d0(%rbp)
movl $0x6, -0x1fc(%rbp)
leaq 0x10308(%rip), %rdx     # 0x14193
leaq -0x1fc(%rbp), %rsi
callq 0x70b0
jmp 0x3e99
leaq -0xb0(%rbp), %rdi
movq %rdi, -0x1d0(%rbp)
movl $0x7, -0x200(%rbp)
leaq 0x102e2(%rip), %rdx     # 0x1419a
leaq -0x200(%rbp), %rsi
callq 0x70b0
jmp 0x3ec6
leaq -0x88(%rbp), %rdi
movq %rdi, -0x1d0(%rbp)
movl $0x8, -0x204(%rbp)
leaq 0x102bc(%rip), %rdx     # 0x141a1
leaq -0x204(%rbp), %rsi
callq 0x71b0
jmp 0x3ef3
leaq -0x60(%rbp), %rdi
movq %rdi, -0x1d0(%rbp)
movl $0x9, -0x208(%rbp)
leaq 0x10297(%rip), %rdx     # 0x141a6
leaq -0x208(%rbp), %rsi
callq 0x7330
jmp 0x3f1d
leaq -0x1c8(%rbp), %rax
movq %rax, -0x38(%rbp)
movq $0xa, -0x30(%rbp)
leaq -0x20a(%rbp), %rdi
movq %rdi, -0x3e0(%rbp)
callq 0x73d0
movq -0x3d8(%rbp), %rdi
movq -0x3e0(%rbp), %r8
movq -0x38(%rbp), %rsi
movq -0x30(%rbp), %rdx
leaq -0x209(%rbp), %rcx
callq 0x73f0
jmp 0x3f67
movq -0x3d0(%rbp), %rax
movq -0x3d8(%rbp), %rcx
movb $0x0, -0x20b(%rbp)
movq %rcx, 0x28(%rax)
leaq -0x20a(%rbp), %rdi
callq 0x74c0
leaq -0x1c8(%rbp), %rax
movq %rax, -0x3f0(%rbp)
addq $0x190, %rax            # imm = 0x190
movq %rax, -0x3e8(%rbp)
movq -0x3e8(%rbp), %rdi
addq $-0x28, %rdi
movq %rdi, -0x3f8(%rbp)
callq 0x73b0
movq -0x3f0(%rbp), %rcx
movq -0x3f8(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x3e8(%rbp)
jne 0x3fa7
movl $0x30, %edi
callq 0x32f0
movq %rax, -0x400(%rbp)
movb $0x1, -0x3c5(%rbp)
leaq -0x3b0(%rbp), %rdi
movq %rdi, -0x3b8(%rbp)
movb $0x30, -0x3b9(%rbp)
leaq 0x101a3(%rip), %rdx     # 0x141af
leaq -0x3b9(%rbp), %rsi
callq 0x74e0
jmp 0x401a
leaq -0x388(%rbp), %rdi
movq %rdi, -0x3b8(%rbp)
movb $0x31, -0x3ba(%rbp)
leaq 0x1017e(%rip), %rdx     # 0x141b4
leaq -0x3ba(%rbp), %rsi
callq 0x7560
jmp 0x4044
leaq -0x360(%rbp), %rdi
movq %rdi, -0x3b8(%rbp)
movb $0x32, -0x3bb(%rbp)
leaq 0x10158(%rip), %rdx     # 0x141b8
leaq -0x3bb(%rbp), %rsi
callq 0x75e0
jmp 0x406e
leaq -0x338(%rbp), %rdi
movq %rdi, -0x3b8(%rbp)
movb $0x33, -0x3bc(%rbp)
leaq 0x10136(%rip), %rdx     # 0x141c0
leaq -0x3bc(%rbp), %rsi
callq 0x7660
jmp 0x4098
leaq -0x310(%rbp), %rdi
movq %rdi, -0x3b8(%rbp)
movb $0x34, -0x3bd(%rbp)
leaq 0x10115(%rip), %rdx     # 0x141c9
leaq -0x3bd(%rbp), %rsi
callq 0x74e0
jmp 0x40c2
leaq -0x2e8(%rbp), %rdi
movq %rdi, -0x3b8(%rbp)
movb $0x35, -0x3be(%rbp)
leaq 0x100f0(%rip), %rdx     # 0x141ce
leaq -0x3be(%rbp), %rsi
callq 0x76e0
jmp 0x40ec
leaq -0x2c0(%rbp), %rdi
movq %rdi, -0x3b8(%rbp)
movb $0x36, -0x3bf(%rbp)
leaq 0x100cd(%rip), %rdx     # 0x141d5
leaq -0x3bf(%rbp), %rsi
callq 0x75e0
jmp 0x4116
leaq -0x298(%rbp), %rdi
movq %rdi, -0x3b8(%rbp)
movb $0x37, -0x3c0(%rbp)
leaq 0x100ab(%rip), %rdx     # 0x141dd
leaq -0x3c0(%rbp), %rsi
callq 0x7560
jmp 0x4140
leaq -0x270(%rbp), %rdi
movq %rdi, -0x3b8(%rbp)
movb $0x38, -0x3c1(%rbp)
leaq 0x10085(%rip), %rdx     # 0x141e1
leaq -0x3c1(%rbp), %rsi
callq 0x75e0
jmp 0x416a
leaq -0x248(%rbp), %rdi
movq %rdi, -0x3b8(%rbp)
movb $0x39, -0x3c2(%rbp)
leaq 0x10063(%rip), %rdx     # 0x141e9
leaq -0x3c2(%rbp), %rsi
callq 0x7760
jmp 0x4194
leaq -0x3b0(%rbp), %rax
movq %rax, -0x220(%rbp)
movq $0xa, -0x218(%rbp)
leaq -0x3c4(%rbp), %rdi
movq %rdi, -0x408(%rbp)
callq 0x7800
movq -0x400(%rbp), %rdi
movq -0x408(%rbp), %r8
movq -0x220(%rbp), %rsi
movq -0x218(%rbp), %rdx
leaq -0x3c3(%rbp), %rcx
callq 0x7820
jmp 0x41ea
movq -0x3d0(%rbp), %rax
movq -0x400(%rbp), %rcx
movb $0x0, -0x3c5(%rbp)
movq %rcx, 0x30(%rax)
leaq -0x3c4(%rbp), %rdi
callq 0x78f0
leaq -0x3b0(%rbp), %rax
movq %rax, -0x418(%rbp)
addq $0x190, %rax            # imm = 0x190
movq %rax, -0x410(%rbp)
movq -0x410(%rbp), %rdi
addq $-0x28, %rdi
movq %rdi, -0x420(%rbp)
callq 0x77e0
movq -0x418(%rbp), %rcx
movq -0x420(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x410(%rbp)
jne 0x422a
jmp 0x4435
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1e0(%rbp)
movl %eax, -0x1e4(%rbp)
movq -0x1d0(%rbp), %rax
leaq -0x1c8(%rbp), %rcx
cmpq %rax, %rcx
movq %rax, -0x428(%rbp)
je 0x42bd
movq -0x428(%rbp), %rdi
addq $-0x28, %rdi
movq %rdi, -0x430(%rbp)
callq 0x73b0
movq -0x430(%rbp), %rax
leaq -0x1c8(%rbp), %rcx
cmpq %rcx, %rax
movq %rax, -0x428(%rbp)
jne 0x428c
jmp 0x432b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1e0(%rbp)
movl %eax, -0x1e4(%rbp)
leaq -0x20a(%rbp), %rdi
callq 0x74c0
leaq -0x1c8(%rbp), %rax
movq %rax, -0x440(%rbp)
addq $0x190, %rax            # imm = 0x190
movq %rax, -0x438(%rbp)
movq -0x438(%rbp), %rdi
addq $-0x28, %rdi
movq %rdi, -0x448(%rbp)
callq 0x73b0
movq -0x440(%rbp), %rcx
movq -0x448(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x438(%rbp)
jne 0x42f8
jmp 0x432b
testb $0x1, -0x20b(%rbp)
jne 0x4336
jmp 0x4347
movq -0x3d8(%rbp), %rdi
movl $0x30, %esi
callq 0x3300
jmp 0x4447
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1e0(%rbp)
movl %eax, -0x1e4(%rbp)
movq -0x3b8(%rbp), %rax
leaq -0x3b0(%rbp), %rcx
cmpq %rax, %rcx
movq %rax, -0x450(%rbp)
je 0x43a9
movq -0x450(%rbp), %rdi
addq $-0x28, %rdi
movq %rdi, -0x458(%rbp)
callq 0x77e0
movq -0x458(%rbp), %rax
leaq -0x3b0(%rbp), %rcx
cmpq %rcx, %rax
movq %rax, -0x450(%rbp)
jne 0x4378
jmp 0x4417
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1e0(%rbp)
movl %eax, -0x1e4(%rbp)
leaq -0x3c4(%rbp), %rdi
callq 0x78f0
leaq -0x3b0(%rbp), %rax
movq %rax, -0x468(%rbp)
addq $0x190, %rax            # imm = 0x190
movq %rax, -0x460(%rbp)
movq -0x460(%rbp), %rdi
addq $-0x28, %rdi
movq %rdi, -0x470(%rbp)
callq 0x77e0
movq -0x468(%rbp), %rcx
movq -0x470(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x460(%rbp)
jne 0x43e4
jmp 0x4417
testb $0x1, -0x3c5(%rbp)
jne 0x4422
jmp 0x4433
movq -0x400(%rbp), %rdi
movl $0x30, %esi
callq 0x3300
jmp 0x4447
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x470, %rsp            # imm = 0x470
popq %rbp
retq
movq -0x1e0(%rbp), %rdi
callq 0x34d0
nopw %cs:(%rax,%rax)