polygon
来源:互联网 发布:中国科学技术大学知乎 编辑:程序博客网 时间:2024/05/01 08:13
描述:
在一个周长为10000的圆上等距分布着n个点,即这n个点是一个正n边形的顶点。现在要另加m个点到圆上,新加的m个点可以任意选择位置(可以与原有的点重合)。然后将这n+m个点中的一些点延圆周移动,最终使n+m个点均匀分布,即在一个正n+m边形的顶点上。输出最小总移动距离。
输入:
输入两个整数 n, m。 (2≤n≤1000, 1≤m≤1000).
输出:
输出最小总移动距离,保留4位小数。
输入样例:
sample input #1 2 1 sample input #2 2 3 sample input #3 3 1 sample input #4 10 10
输出样例:
sample output #1 1666.6667 sample output #2 1000.0 sample output #3 1666.6667 sample output #4 0.0 图对应前3个样例
- polygon
- Polygon
- Polygon建模
- Polygon(二)
- Polygon (p1179)
- Nef polygon
- poj1179 Polygon
- HDU4752 Polygon
- HDU4752 Polygon
- poj_2007_Scrambled Polygon
- Polygon Division
- poj1179 Polygon
- UVA11971 - Polygon
- Farey Polygon
- POJ2007Scrambled Polygon
- UVA11971 - Polygon
- UVa11971 Polygon
- Polygon[IOI1998]
- 城堡
- 右键菜单
- C#中利用存储过程(含有参数)返回dataset
- 在 Linux 上找出并解决程序错误的主要方法
- C++ vector 排序
- polygon
- 从网上搜集的几种数据分页的总结
- 路面修整
- 数据挖掘主要解决的四类问题
- 流星雨
- 手抄本
- Spell checker
- 保护花朵
- android ListView和BaseAdapter以及事件