The Gateway to Computer Science Excellence
First time here? Checkout the FAQ!
x
+2 votes
318 views

Specify an adjacency-lists representation of the undirected graph given above.

in Graph Theory by Boss (29.5k points)
edited by | 318 views

1 Answer

+3 votes
Best answer

An adjacency list is an array $A$ of separate lists.

Each element of the array $A_{i}$ is a list, which contains all the vertices that are adjacent to vertex $i$.

$A_{1}\rightarrow2\rightarrow3\rightarrow5$

$A_{2}\rightarrow1\rightarrow3$

$A_{3}\rightarrow1\rightarrow2\rightarrow4\rightarrow5$

$A_{4}\rightarrow3\rightarrow5$

$A_{5}\rightarrow1\rightarrow3\rightarrow4$

by Boss (17.2k points)
selected by

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
49,831 questions
54,735 answers
189,349 comments
80,097 users