UVA10325 The Lottery

Description

[problemUrl]: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=15&page=show_problem&problem=1266 [PDF](https://uva.onlinejudge.org/external/103/p10325.pdf) ![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10325/47eafb27afdc91107df0dede3247635c8c9118d2.png)

Input Format

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

Output Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10325/3b284b69dd918e1045ff242ac887e8b9af5cbb95.png)