-
Dynamic programming method, algorithm programming, if there are other questions,...
动态规划法,算法程序设计,如果有其他问题,请给我发邮件-Dynamic programming method, algorithm programming, if there are other questions, please send me e-mail
- 2022-06-30 11:29:46下载
- 积分:1
-
classic Chinese Remainder Theorem solving program, you have to import the soluti...
经典的中国剩余定理求解程序,输入你所要解的同余式即可按定理求解!-classic Chinese Remainder Theorem solving program, you have to import the solution congruence theorems can be solved by!
- 2022-02-24 09:16:20下载
- 积分:1
-
径向基函数隐式曲面代码
包含径向基函数的隐式曲面重建算法,可以得到隐式曲面的表达式,包含求解的过程,和一些主要的算法。
- 2022-01-26 01:39:59下载
- 积分:1
-
黄金分割法,抛物线插值法,单行替换法是机械优化设计中的三中重要方法。...
黄金分割法,抛物线插值法,单行替换法是机械优化设计中的三中重要方法。-Golden section method, parabolic interpolation method, one-way is to replace mechanical optimal design method of the three most important.
- 2022-01-25 23:40:14下载
- 积分:1
-
C语言实现图书管理系统
1)能录入新商品信息2)能对商品信息进行查询: 可以按编号,按商品名称,按商品类别,按供货商,按产地进行查询3)可以对商品信息进行修改,删除4)商品销售:输入销售单,根据商品编号,读取并显示商品信息,根据销售数量,修改库存。5)可以记录销售的记录,以备查询。6)商品销售信息查询:7)统计
- 2022-02-21 21:46:26下载
- 积分:1
-
plural example
复数示例-plural example
- 2022-03-11 09:34:46下载
- 积分:1
-
This file contains the complete code of six stand
此文件包含用于聚类分析的六个独立Fortran程序的完整代码
- 2022-09-13 12:50:02下载
- 积分:1
-
关于最佳算法的实现
关于最佳算法的实现 -Realize the best algorithm on
- 2022-03-18 01:29:40下载
- 积分:1
-
找钱张数最少
二、问题
现只有面额为 11元、5元、1元的三种人民币。
给定一个 数目为 money 的人民币,如何用这三种面额的人民币 找开它,且用的人民币张数最少
如:给定 10元,我们可以有以下找法:
2张 5元面额
1张 5元面额 + 5 张 1元面额
10张 1元面额
我们 选择第一种找法。只用两张人民币。
三、分析
利用动态规划法可以找到最优解。
利用贪心算法可以找到最优解(问题满足贪心选择性质时。该找钱问题在 11、5、1三种面额的情况下不满足该性质)
或者找到近似 最优解(在本题设定的三种面额的情况下 便是如此)
如果现在要找开 15元钱,则
- 2022-03-06 11:17:09下载
- 积分:1
-
this to find out the shortest path for various nodes
this to find out the shortest path for various nodes-this is to find out the shortest path for various nodes
- 2022-02-03 14:28:49下载
- 积分:1