implemented saving grid to file and loading grid to file in the
HelperFunctions class as two methods.