Graph theory worksheet with answers

Free printable Graph theory worksheet: 6 problems from easy to exam level, with an answer key. Print it or save it as a PDF.

For teachers: free to print, copy and use in class. Every new worksheet has new values and its own answer key. A link to ExamProblems on your course page is appreciated.

Name: ____________________   Date: ____________

1.Easy
ABCDE

Exactly one vertex of the graph has degree 3. Click it.

deg = 3
  1. 1A
  2. 2B
  3. 3C
  4. 4D
  5. 5E
2.Easy

A tree has 29 vertices. How many edges |E| does it have?

|V| = 29
|E| =
3.Medium

A tree has 2 vertices of degree 3, 4 vertices of degree 4, 3 vertices of degree 5, 2 vertices of degree 2, and all its other vertices are leaves (degree 1). How many leaves L does it have?

2 × deg 34 × deg 43 × deg 52 × deg 2
L =
4.Medium

A connected graph has 17 vertices and 19 edges. How many edges k must be removed to leave a spanning tree?

|V| = 17|E| = 19
k =
5.Hard
131111261615ABCDE

Kruskal’s algorithm builds a minimum spanning tree. Click the edge it adds as edge number 3; skipped edges do not count.

k = 3
  1. 1edge AB
  2. 2edge AC
  3. 3edge BC
  4. 4edge BD
  5. 5edge CE
  6. 6edge DE
  7. 7edge BE
6.Hard
115111361531012ABCDEFG

Use Dijkstra’s algorithm to find the length d(D) of the shortest path from A to D in the weighted graph.

start: Aend: D
d(D) =

Answer key

  1. 1. C
  2. 2. |E| = 28
  3. 3. L = 21
  4. 4. k = 3
  5. 5. edge AC
  6. 6. d(D) = 24

Full step-by-step solutions: practise this topic on examproblems.com.