generate_text function

A helper function that takes result from the simulators and produces text output