Pergunta de entrevista da empresa AMD

write code for different types of implementation of the graph.