UVA11495 Bubbles and Buckets

Description

[problemUrl]: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=26&page=show_problem&problem=2490 [PDF](https://uva.onlinejudge.org/external/114/p11495.pdf) ![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA11495/6c2fb5aafee0654171de2c36c60dd18efd6b0e90.png)

Input Format

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

Output Format

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