adding results to the display function