Implemented adding code
Construct graph
Construct graph