Fact one: graph is a tree on nn vertices, it has exactly n−1n−1 edges

Fact two: sum of all degrees is twice number of edges

so there are 29 edges, total degree is 29*2 = 58. now 1 vertex has 20 degree, so remianing degree = 38 and remaining vertex = 29

let number of vertex with degree 1 be 'x', so number of remaining vertex will be (29-x) and they must

be degree 2.

x*1 + (29-x)*2 = 38 , x =20