UVA702 The Vindictive Coach

Description

[problemUrl]: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=9&page=show_problem&problem=643 [PDF](https://uva.onlinejudge.org/external/7/p702.pdf) ![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA702/7c29f7aee632d8c65acbff01029ad9595b4681fe.png)

Input Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA702/3446545094502113354ae1ff629138975329920f.png)

Output Format

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