Generating graphs for resulted programs