登录
首页 » 数据结构 » 一辆汽车加满油后可行驶n公里。旅途中有若干个加油站。设计一个有效算法,指出应在哪些加油站停靠加油,使沿途加油次数最少。对于给定的n和k个加油站位置,编程计算最少...

一辆汽车加满油后可行驶n公里。旅途中有若干个加油站。设计一个有效算法,指出应在哪些加油站停靠加油,使沿途加油次数最少。对于给定的n和k个加油站位置,编程计算最少...

于 2023-08-07 发布 文件大小:2.70 kB
0 152
下载积分: 2 下载次数: 1

代码说明:

一辆汽车加满油后可行驶n公里。旅途中有若干个加油站。设计一个有效算法,指出应在哪些加油站停靠加油,使沿途加油次数最少。对于给定的n和k个加油站位置,编程计算最少加油次数。并证明算法能产生一个最优解-Fill up the car after driving an n km. There are a number of gas stations journey. Design an efficient algorithm that at which stations should stop to refuel along the way so that the least number of refueling. For a given n and k-station location, the calculation program for at least the number of refueling. And to prove that the algorithm can produce an optimal solution

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • delphi 制作的电梯程序
    资源描述delphi 制作的电梯程序,智能控制上下人数,停留层完全按照实际操作来,设计结构精细,适合练手.组件简单
    2022-02-05 21:09:29下载
    积分:1
  • 无限大整类 用链表实现无限大整的运算。 在进行大整运算时可以拿它当函,直接调用...
    无限大整数类 用链表实现无限大整数的运算。 在进行大整数运算时可以拿它当函数,直接调用-Infinite integer Class List realize infinite integer arithmetic. In large integer operations can use it as a function of the direct call
    2022-01-26 06:54:36下载
    积分:1
  • 完全基于ODBC API封装的库访问库源代码。可以支持主流库。接口间接,清晰。...
    完全基于ODBC API封装的数据库访问库源代码。可以支持主流数据库。接口间接,清晰。-Based entirely on the ODBC API package, database access library source code. Can support the mainstream databases. Interface, indirect and clear.
    2022-02-27 08:50:37下载
    积分:1
  • 一个中关于链表的实验,创建链表等,包括增删查改...
    一个数据结构中关于链表的实验,创建链表等,包括增删查改-A data structure on the list of experiments, create list, including additions and deletions to search
    2022-12-13 20:05:03下载
    积分: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
  • java和算法(第二版)
    Java数据结构和算法(第二版)-lafore著,教材中的范例程序,用JAVA语言,-Java data structures and algorithms (second edition)-lafore, and textbook examples of procedures, using JAVA language,
    2022-02-09 20:19:56下载
    积分:1
  • 任意长整相加问题 任意输入两个任意长的整进行相加 可以得出正确果,...
    任意长整数相加问题 任意输入两个任意长的整数进行相加 可以得出正确结果,-arbitrary sum of long integer problem indiscriminate importation of two arbitrarily long integer can be drawn together for the right result,
    2023-02-21 21:55:03下载
    积分:1
  • VC下实现响铃的小程序,自动生成一个小文件,可以用realplayer等播放器打开...
    VC下实现响铃的小程序,自动生成一个小文件,可以用realplayer等播放器打开-VC under Neither the small program automatically generates a small file that can be used REALPLAYER other players open
    2022-06-15 11:58:02下载
    积分:1
  • 学生身份识别模块
    如今 internetplays 在学生的日常生活中的重要作用。每个学生要信息他们的指尖,现在高校打算不致太过挤迫,对基本和必要信息要更加困难的一天皇陵。被一群学生我们的团队也经历了这些革新生活中的问题。为此学生 InformationSuite 将发挥重要的作用。由信息 wemean:-(i) 会期结果(ii) 每日通知(iii) 每天的出勤记录< 跨度 style="font-size:11.0pt;line-height:115%;font-family:""> (iv) Syllabusof 本学期等。
    2022-12-17 06:55:03下载
    积分:1
  • 清华大学严蔚敏老师《题集(C语言版)》实验3.4 串基本操作的演示...
    清华大学严蔚敏老师《数据结构题集(C语言版)》实验3.4 串基本操作的演示-Tsinghua University, Yan Wei-Min teacher
    2022-03-16 13:12:33下载
    积分:1
  • 696518资源总数
  • 106155会员总数
  • 8今日下载