文件名称:03
- 所属分类:
- 其他小程序
- 资源属性:
- [Windows] [Visual.Net] [源码]
- 上传时间:
- 2012-11-26
- 文件大小:
- 966kb
- 下载次数:
- 0次
- 提 供 者:
- c*
- 相关连接:
- 无
- 下载说明:
- 别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容均来自于网络,请自行研究使用
给定n个大小不等的圆c1,c2,c3,...,cn,现要将这n个圆排进一个矩形框中,且要求各圆与矩形框的底边相切。圆排列问题要求从n个圆的所有排列中找出有最小长度的圆排列。编程任务:对于给定的n个圆,设计算法,计算n个圆的最佳排列方案,使其长度达到最小。
输入:第一行有1个正整数n (圆的个数1≤n≤20)
接下来的1行有n个数,表示n个圆的半径
输出:将计算出的最小圆排列的长度(保留2位小数)
例如:
输入:
3
1 1 2
输出:
7.-Given n-size circle c1, c2, c3 ,..., cn, is a circular to this n into a rectangular box, and asked to circle and tangent to the bottom edge of the rectangular box. With the issue of yen from the n-all arranged in a circle to identify the length of the circle with the smallest. Programming tasks: for a given round of the n-designed algorithm to calculate the best n-round with programs to minimize the length. Input: the first line there is a positive integer n (the number of round 1 ≤ n ≤ 20) then there is n number of line 1, that n the radius of a circle Output: the minimum will be calculated with the length of a round (reservations 2 decimal) For example: Input: 3 1 1 2 output: 7.66
输入:第一行有1个正整数n (圆的个数1≤n≤20)
接下来的1行有n个数,表示n个圆的半径
输出:将计算出的最小圆排列的长度(保留2位小数)
例如:
输入:
3
1 1 2
输出:
7.-Given n-size circle c1, c2, c3 ,..., cn, is a circular to this n into a rectangular box, and asked to circle and tangent to the bottom edge of the rectangular box. With the issue of yen from the n-all arranged in a circle to identify the length of the circle with the smallest. Programming tasks: for a given round of the n-designed algorithm to calculate the best n-round with programs to minimize the length. Input: the first line there is a positive integer n (the number of round 1 ≤ n ≤ 20) then there is n number of line 1, that n the radius of a circle Output: the minimum will be calculated with the length of a round (reservations 2 decimal) For example: Input: 3 1 1 2 output: 7.66
(系统自动生成,下载前可以参看下载内容)
下载文件列表
圆排列
......\Debug
......\.....\圆排列.exe
......\.....\圆排列.ilk
......\.....\圆排列.pdb
......\圆排列
......\......\Debug
......\......\.....\BuildLog.htm
......\......\.....\mt.dep
......\......\.....\vc90.idb
......\......\.....\vc90.pdb
......\......\.....\圆排列.exe.intermediate.manifest
......\......\.....\圆排列.obj
......\......\圆排列.cpp
......\......\圆排列.vcproj
......\......\圆排列.vcproj.CJTC1989-PC.caojun.user
......\圆排列.ncb
......\圆排列.sln
......\Debug
......\.....\圆排列.exe
......\.....\圆排列.ilk
......\.....\圆排列.pdb
......\圆排列
......\......\Debug
......\......\.....\BuildLog.htm
......\......\.....\mt.dep
......\......\.....\vc90.idb
......\......\.....\vc90.pdb
......\......\.....\圆排列.exe.intermediate.manifest
......\......\.....\圆排列.obj
......\......\圆排列.cpp
......\......\圆排列.vcproj
......\......\圆排列.vcproj.CJTC1989-PC.caojun.user
......\圆排列.ncb
......\圆排列.sln