Finished DeBruijin from patterns problem