Why is the answer option D and not option B?

How can we represent a graph with N vertices using a 1D vector of int of size n+1?