UVA10251 Min-Max Cake

Description

[problemUrl]: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=14&page=show_problem&problem=1192 [PDF](https://uva.onlinejudge.org/external/102/p10251.pdf) ![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10251/30c925d8f94b8dfdb1139e3c0d3fe52a72bd93ab.png)

Input Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10251/71bd0a0c8acfce6f16bb410f4836c99563866164.png)

Output Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10251/0bc6e11827900ff5e182c1255bb798e260d5e885.png)