[Algorithm] DFS和Backtracking的区别
文章目录
| - | DFS | Backtracking |
| Target Structure | Actual Tree/Graph Structure | Any type of structure where portions of the domain can be eliminated (Chess Board, matrix, implicit tree) |
| Definition | A specific form of backtracking related to searching tree/graph structures | Traverse from the end and prune unacceptable cases |
| Start-At Point | Root of the Tree | End of the Goal |
| Moving Direction | From the root to each branch | From the end moving backwards |
评论
登录后参与技术讨论,分享你的经验与见解。
登录 / 注册暂无评论