added function to sanitize a graph
sanitized the add-edge method
function to remove vertices from a graph