当前位置:网站首页>Data Organization---Chapter 6 Diagram---Graph Traversal---Multiple Choice Questions
Data Organization---Chapter 6 Diagram---Graph Traversal---Multiple Choice Questions
2022-08-02 14:01:00 【A life without a root, gone with the wind, such as dust on the 】
1What is the single-source shortest path problem
Given a starting point in the graph, find the shortest distance from the starting point to other vertices.
When the weights of each edge are equal, the breadth-first algorithm can solve the single-source shortest path problem
But not when the weights are not equal, because the breadth-first algorithm does not consider the weights, it only considers the number of edges.
2 Breadth-first traversal is similar to level-order traversal in a tree, and depth-first search traversal is similar to pre-order traversal in a tree.
3 Breadth-first search requires a queue, and depth-first search requires a stack.
4 For a non-connected undirected graph G, using depth-first traversal to access all vertices, the number of calls to DFS in the DFSTraverse function is exactly equal to?
5 Breadth First Search Spanning Tree for Graph, Depth First Search Spanning Tree for Graph
边栏推荐
- 为什么四个字节的float表示的范围比八个字节的long要广
- Kunpeng devkit & boostkit
- 如何选择正规的期货交易平台开户?
- GTK:Gdk-CRITICAL **: IA__gdk_draw_pixbuf: assertion ‘GDK_IS_DRAWABLE (drawable)‘ failed
- 关于市场后市的发展预测? 2021-05-23
- How to create short images and short videos from the media?How to make the click volume reach 10W?
- wait() ,notify(),notifyAll()以及wait()与sleep()比较
- [C language] Analysis of function recursion (3)
- WiFi Association&Omnipeek抓包分析
- SQL函数 USER
猜你喜欢
随机推荐
【C语言】剖析函数递归(1)
How to create short images and short videos from the media?How to make the click volume reach 10W?
FreeBSD bnxt以太网驱动源码阅读记录三:
【C语言】虐打循环练习题(2)
你接受不了60%的暴跌,就没有资格获得6000%的涨幅 2021-05-27
stack && queue
Awesome!Alibaba interview reference guide (Songshan version) open source sharing, programmer interview must brush
els 长条碰撞变形判断
苏州大学:从 PostgreSQL 到 TDengine
你真的懂单例模式么
【ONE·Data || 排序入门】
mysql的case when如何用
机器学习——交叉验证法
js array recursively use
关于Google词向量模型(googlenews-vectors-negative300.bin)的导入问题
web测试和app测试的区别?
Geoffery Hinton:深度学习的下一个大事件
劲爆!阿里巴巴面试参考指南(嵩山版)开源分享,程序员面试必刷
二进制中1的个数
【C语言】手撕循环结构 ——do...while语句及循环练习题(1)