My code runs in almost all the ways I need it to up until the return statement, where it segmentation faults. I believe this is because of the implementation of my erase() f