2020牛客暑期多校訓練營(第二場)C Cover the Tree

這題比賽的時候想了半天,碼了出來後發現是錯的,當場無語, 後來hl學長告訴先跑一遍dfs序而後記錄一下度爲1的點出現的順序,再輸出。具體代碼講ios #include<iostream> #include<stdio.h> #include<math.h> #include<string.h> #include<string> #include<vector> #include<queue> #i
相關文章
相關標籤/搜索