Khan.randRange(6, 10) Khan.randRange(numV, (numV * (numV - 1))/2) Khan.randRange(4,6) Khan.randRange(2,4) Khan.randRange(2,4) (numV * pointerB) + (numE * (vertB + edgeB + pointerB))

WARNING! Read the conditions for the problems in this set very carefully!

Assume for a directed graph with numV vertices and numE edges that a vertex index requires vertB bytes, a pointer requires pointerB bytes, and that edge weights require edgeB bytes. Calculate the byte requirements for an adjacency list.

ANS

Adjacency list has an array (of size |V|) which points to a list of edges.

Every edge appears once on the list. And for each edge there has to be a vertex ID, a weight, and a pointer to the next edge.

(V * pointer) + (E * (vertex_index + edge_weight + pointer)) bytes = ANS