finished writing threaded merge with heap sort, debugging