Problem Summary
Given a tree with N nodes, find the maximum number of edges that can be removed from it to get a forest such that each tree of the forest contains an even number of nodes.
Given a graph with vertices 1,2,…,N and M undirected edges, find the maximal length of a round trip.
The tour should have two parts. Let the first part be A[1]->A[2]->…->A[K], the second be B[1]->B[2]->…->B[P]. They should satisfy: