run the existing code and set up the environment