Save the result of each step, instead of having to start from the beginning if a change is made several steps down the script