HDU 2134 Cuts the cake
http://acm.hdu.edu.cn/showproblem.php?pid=2134
But there is a difficult problem.which is how to make each preson get equally many cake. kiki is not good at match, so she wants you help her solve this problem.
#include <bits/stdc++.h>
using namespace std; int main() {
double R;
while(cin >> R) {
if(R == 0)
break; double r1, r2;
r1 = sqrt(R * R / 3.0);
r2 = sqrt(R * R * 2.0 / 3.0); printf("%.3lf %.3lf\n", r1, r2);
}
return 0;
}
HDU 2134 Cuts the cake的更多相关文章
- hdu 4454 Stealing a Cake(三分之二)
pid=4454" target="_blank" style="">题目链接:hdu 4454 Stealing a Cake 题目大意:给定 ...
- HDU 5640 King's Cake GCD
King's Cake 题目连接: http://acm.hdu.edu.cn/showproblem.php?pid=5640 Description It is the king's birthd ...
- HDU 4762 Cut the Cake(公式)
Cut the Cake Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Tota ...
- HDU 5640 King's Cake
King's Cake Problem Description It is the king's birthday before the military parade . The ministers ...
- hdu 5640 King's Cake(BestCoder Round #75)
King's Cake Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total ...
- HDU 4762 Cut the Cake
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4762 题目大意:将n个草莓随机放在蛋糕上,草莓被看做是点,然后将蛋糕平均切成m份,求所有草莓在同一块蛋 ...
- hdu 4762 Cut the Cake概率公式
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4762 题目大意:一个圆形蛋糕,现在要分成M个相同的扇形,有n个草莓,求n个草莓都在同一个扇形上的概率. ...
- hdu 5640 King's Cake(模拟)
Problem Description It is the king's birthday before the military parade . The ministers prepared ...
- hdu 4454 Stealing a Cake (三分)
Stealing a Cake Time Limit: 5000/2000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) ...
随机推荐
- 自己写个activex控件,如何知道他的classid(转载)
在网页里用的时候需要知道他的classid我在代码中看到有 const GUID CDECL BASED_CODE _tlid = { 0x89201950, 0x2CAC, 0x4CF7, { 0x ...
- MySQL下查看和赋予权限
磨砺技术珠矶,践行数据之道,追求卓越价值 回到上一级页面: PostgreSQL杂记页 回到顶级页面:PostgreSQL索引页 [作者 高健@博客园 luckyjackgao@gmail. ...
- 对大表进行全表更新,导致 Replication 同步数据的过程十分缓慢
在Publisher database中更新一个big table,数据行数是3.4亿多.由于没有更新 clustered Index key,因此,只产生了3.4亿多个Update Commands ...
- 解决在控制层springmvc框架发出的400状态的错误
错误场景: 错误分析: 这也是我第一次遇到这个类型的异常,400响应状态代表:客户端发出的请求中携带的参数与服务器端接受的参数类型不匹配,进一步就是说我后台的实体类中数据类型为Date,而前台传递过来 ...
- Docker创建数据卷
当程序在容器中运行时,需要与其他容器中的程序或者容器外部的程序进行文件读写操作时,就需要进行数据的交换:容器内部的文件系统,是一个临时层,当容器停止运行并被删除时,这个临时层就会被一同丢弃:为了达到从 ...
- C++ chrono 库中的 steady_clock 和 system_clock
C++11 中提供了一个计时的标准库 <chrono>; 里面有三种时钟 clock: steady_clock, system_clock 和 high_resolution_clock ...
- 高可用OpenStack(Queen版)集群-2.基础服务
参考文档: Install-guide:https://docs.openstack.org/install-guide/ OpenStack High Availability Guide:http ...
- React Native移动开发实战-3-实现页面间的数据传递
React Native使用props来实现页面间数据传递和通信.在React Native中,有两种方式可以存储和传递数据:props(属性)以及state(状态),其中: props通常是在父组件 ...
- git 创建管理多用户
<搬运> Windows下Git多账号配置,同一电脑多个ssh-key的管理 一台电脑上的git同时使用两个github账户 git之https或http方式设置记住用户名和密码的方法
- 《The Mythical Man-Month(人月神话)》读后感(2)
第10章 未雨绸缪 在化学领域中,在实验室可以进行的反应过程,并不能在工厂中一步实现.一个被称为“ 实验性工厂(pilot planet)”的中间步骤是非常必要的,它会为提高产量和在缺乏保护的环境下运 ...