求图的中心点。设V是有向图G的一个顶点, V的偏心度定义...
求图的中心点。设V是有向图G的一个顶点, V的偏心度定义为: Find the central point of the graph. Let V be a vertex of the graph G, the definition of the eccentricity of V is: max{dist(w,v),∀w∈V(G)} 如果v是有向图G中具有最小偏心度的顶点,则称顶点v是G的中心点。 If the eccentricity of v is minimal in the graph G, then we call V a central point of G. 请从以下代码语句中选择正确的5条,填入空白处。按空白的标号顺序依次列出代码语句的标号,用一个空格分隔。如A F D H C Please choose 5 statements from the following, and put them into the blanks. List the number of the statement you choose according to the order of the blanks, and separate them with a single blank space. For instance, A F D H C. C++代码: void FLOYD_PXD(AdjMatrix g){ // 对以带权邻接矩阵表示的有向图g,求其中心点。 AdjMatrix w = g; for(k = 1; k <= n; k++) for(i="1;" i++) for(j="1;" j j++) if((1) ) (2) ; v="1;" dist="MAXINT;" j++){ s="0;" i (3) (4) ){ (5) } for printf("有向图g的中心点是顶点%d,偏心度%d\n", v, dist); }python代码:def floyd_pxd(adjmatrix g): adjmatrix w="g" k in range(1, n+1): range (1, if (): print("有向图g的中心点是" + str(v) ",顶点偏心度" str(dist)) 选项: src="http://static.jiandati.com/a9585d5-chaoxing2016-284362.png">