UVA10216 The Optimal Coffee Shop!!

Description

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

Input Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10216/fdb0b05d83f8ef352f5891f7d0523fc8cf76a93f.png)

Output Format

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