Topic: Graph Theory Problem / Level: beginner

Problem: Write a program to find all nodes in a graph that have degree 2.

Run the code to see the output here...