extend_match now produces the same Needleman-Wunsch alignments as the original C++ code for the first four chunks