我们直接暴力的深搜怎么切就行了,

每一刀切的方案只有横着和竖着,横竖又分在几等分点切,

因为要保证每个人的面积相同,所以比较好处理了,第几个几等分点就

分给这边几刀。

/**************************************************************
    Problem:
    User: BLADEVIL
    Language: Pascal
    Result: Accepted
    Time: ms
    Memory: kb
****************************************************************/
 
//By BLADEVIL
var
    x, y                            :extended;
    n                               :longint;
     
function max(a,b:extended):extended;
begin
    if a>b then max:=a else max:=b;
end;
 
function min(a,b:extended):extended;
begin
    if a>b then min:=b else min:=a;
end;
 
function dfs(x,y:extended;n:longint):extended;
var
    ans, r                          :extended;
    i                               :longint;
begin
    if x>y then
    begin
        ans:=x; x:=y; y:=ans;
    end;
    if n= then exit(y/x);
    r:=/n; ans:=1e20;
    for i:= to n- do
    begin
        ans:=min(ans,max(dfs(x*r*i,y,i),dfs(x-x*r*i,y,n-i)));
        ans:=min(ans,max(dfs(x,y*i*r,i),dfs(x,y-y*r*i,n-i)));
    end;
    exit(ans);
end;
 
 
begin
    read(x,y,n);
    writeln(dfs(x,y,n)::);
end.

最新文章

  1. Request Entity Too Large for Self Hosted ASP.Net Web API在Selfhost的api后台怎么解决Request Entity Too Large问题
  2. 智能车学习(十三)——角度控制
  3. 获取 Cookie
  4. Dynamic CRM 2013学习笔记(二十七)无代码 复制/克隆方法
  5. java之对象转型2
  6. [HDOJ5933]ArcSoft's Office Rearrangement(贪心)
  7. Centos7安装Zabbix3.0
  8. perf
  9. 条形码Code128源代码
  10. 淘宝的ip地址库
  11. 解决MySQL连接超时Communications link failure due to underlying exception
  12. hdu 3047 Zjnu Stadium
  13. vue.js的devtools安装
  14. 实现在Android 多点手势识别
  15. [移动端] IOS下border-image不起作用的解决办法
  16. WPF 自定义ItemsControl/ListBox/ListView控件样式
  17. mysql批量导出单结构与结构数据表脚本
  18. windows下启动mysql服务
  19. 既然还看不到未来之光,那就从骄阳开始的地方--IT携行
  20. ALGO-123_蓝桥杯_算法训练_A+B problem

热门文章

  1. SQL加、查、改、删、函数
  2. Cookie与Session的一些总结
  3. Vue.js学习 Item12 – 内部响应式原理探究
  4. Ueditor图片缩放的设置
  5. Java实现计算20的阶乘
  6. iOS中使用子线程的完整方法
  7. C#高级功能(四)扩展方法和索引
  8. jqueryMobile应用第一课《构建跨平台APP:jQuery Mobile移动应用实战》连载一(Hello World)
  9. MongoDB 学习笔记(三)—— 修改器的使用
  10. L2-015. 互评成绩