30. 下列何種資料結構最適合用於 BFS 搜尋演算法? (A)STACK (B..-阿摩線上測驗
2F 108新北正式資訊師 大二上 (2017/05/08)
廣度優先搜尋法 Breadth-first search (BFS) is a strategy for searching in a graph.The BFS begins at a root node and inspects all the neighboring nodes. Then for each of those neighbor nodes in turn, it inspects their neighbor nodes which were unvisited, and so on. (參1) 廣度優先搜尋法,是一種圖形(graph)搜索演算法。從圖的某一節點(vertex, node)開始走訪,接著走訪此一節點所有相鄰且未拜訪過的節點,由走訪過的節點繼續進行先廣後深的搜尋。以樹(tree)來說即把同一深度(level)的節點走訪完,再繼續向下一個深度搜尋,直到找到目的節點或遍尋全部節點。 廣度優先搜尋法屬於盲目搜索(uninformed searc... 查看完整內容 |
3F
|