|
|
back to boardSolution is pretty easy Posted by 2ch 7 Feb 2018 21:51 Firstly, the problem asks to find number of edges in minimum edge cover Secondly, the number of such edges plus the number of maximum matching equals to number of vertices, that is N + M Thirdly, you can find the number of max. matching easily with dfs-like algorithm (you can find code online). The answer is N + M - (number of max. matching) |
|
|