-
Order to map any of the distance between two nodes, (2) with two
求图的任两结点间的距离,(2) 用二维数组存放C和A ,C是原成本矩阵,A 是求出的距离矩阵
(3) 算法采用三重循环,其中最外层的循环变量必须代表中间结点,中层的循环变量代表头结点而内层循环变量代表尾结点。
(4) 试着把三层循环变量的顺序作些改变,最外层的循环变量仍代表中间结点,而中层循环变量代表尾结点,内层循环变量代表头结点。把两种做法所得结果作比较,看结果是否相同
(5) 显示结果要清晰易懂
(6) 本题运行结果
-Order to map any of the distance between two nodes, (2) with two-dimensional array of storage C, A, C is the original cost matrix, A is to find the distance matrix (3) The algorithm uses the triple loop, one of the most outer loop variable must be representative of intermediate nodes, the middle loop variable represents the first node and the inner loop variable represents the end nodes. (4) tried to three-loop order of the variables to make some changes, the most outer loop variables still represent intermediate nodes, while the middle loop variable represents the end nodes, the inner loop variable represents the first node. The two approaches to compare the results to see whether the results the same (5) shows the results must be clear and understandable (6) The q
- 2022-04-20 12:55:19下载
- 积分:1
-
模糊查询源码,实现简单的数据库条目查找。
模糊查询源码,实现简单的数据库条目查找。
- 2022-01-26 00:57:19下载
- 积分:1
-
常用算法的C语言描述。里边算法非常详尽。解压即可使用。
常用算法的C语言描述。里边算法非常详尽。解压即可使用。-common algorithms described in C language. Inside algorithm very detailed. Decompression can be used.
- 2023-03-24 02:55:03下载
- 积分:1
-
匈牙利算法实现二分图最大匹配
文件输入输出.
匈牙利算法实现二分图最大匹配
文件输入输出.-Hungarian algorithm bipartite graph maximum matching document input and output.
- 2022-07-19 23:47:19下载
- 积分:1
-
单源点最短路径算法
* 本程序用来实现单源点最短路径(E.Dijkstra)算法
* 在Turbo C2.0编译器下编译通过
* 算法过程中...
单源点最短路径算法
* 本程序用来实现单源点最短路径(E.Dijkstra)算法
* 在Turbo C2.0编译器下编译通过
* 算法过程中
* 每条边的两个顶点和权值由用户输入,格式:1 2 20
* 程序默认源点为第一个顶点
* 算法完成后输出路径长度和路径上的顶点
* 格式为:路径长度:目标顶点
- 2022-03-23 04:50:33下载
- 积分:1
-
topological sorting, data structure of the operations.
拓扑排序,数据结构的作业。-topological sorting, data structure of the operations.
- 2022-02-02 03:01:54下载
- 积分:1
-
WordPress博客系统,可以自由改变中文版,没有钱…
wordpress中文版的部落格系统,可以自由改变,无可金钱衡量-the Chinese version of wordpress blog system that can freely change, no money as a gauge
- 2023-03-16 10:35:04下载
- 积分:1
-
图函数,实现插入,删除,保存,恢复等功能
图函数,实现插入,删除,保存,恢复等功能-Map function, the realization of insert, delete, save and restore functions
- 2022-05-24 06:30:59下载
- 积分:1
-
以一个Maze(m, n)的长方阵表示迷宫, 迷宫的入口是Maze(1,1), 出口是Maze(m, n), Maze(i,j)等于0表示通路, Maze(i,...
以一个Maze(m, n)的长方阵表示迷宫, 迷宫的入口是Maze(1,1), 出口是Maze(m, n), Maze(i,j)等于0表示通路, Maze(i,j)等于1表示障碍。设计一个程序,对任意设定的迷宫,求出一条从入口到出口的通路,或得出没有通路的结论。各个命令以及相关数据的输入格式如下:
输入迷宫:C,接下来一行是m n,其中m是迷宫矩阵行数,n是迷宫矩阵列数,接下来的m行数据是迷宫矩阵,每行n个值,表示一个m*n的迷宫矩阵
求迷宫的一条通路:Q
当输入的命令为E时,程序结束-With a Maze (m, n), said the long square maze, the maze entrance is a Maze (1,1), exports is the Maze (m, n), Maze (i, j) is equal to 0, said channel, Maze (i, j) is equal to 1, said barrier. Designing a program, for any set of the maze, find a path from the entrance to the export, or come to the conclusion there is no path. The various commands and data input format is as follows: Enter the Labyrinth: C, followed by his party mn, where m is the maze of matrix rows, n is a maze of matrix columns, the next line of data is a maze m matrix, each row n- value, indicating an m* n matrix of the labyrinth a maze of pathways: Q when the input command for the E, the end of the process
- 2023-04-15 19:50:03下载
- 积分:1
-
旅行商问题:
某售货员要到若干城市去推销商品,已知各城市之间的路程(或旅费)。他要选定一条从驻地出发,经过每个城市一遍,最后回到驻地的路线,使总的路程(或旅...
旅行商问题:
某售货员要到若干城市去推销商品,已知各城市之间的路程(或旅费)。他要选定一条从驻地出发,经过每个城市一遍,最后回到驻地的路线,使总的路程(或旅费)最小。-traveling salesman problem : A salesman to a number of cities to sell commodities, known the distance between cities (or travel). He selected from a resident, after each city again, the last resident to return to the line, making the total distance (or travel) is the smallest.
- 2023-07-26 02:35:04下载
- 积分:1