UVA11201 The problem of the crazy linguist

Description

[problemUrl]: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=24&page=show_problem&problem=2142 [PDF](https://uva.onlinejudge.org/external/112/p11201.pdf) ![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA11201/bc5b4e2fc8046e82ff54f03ab0c38dec5fbde082.png)

Input Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA11201/42e2781d8e5da8f687a6981499c98af57f9f18c5.png)

Output Format

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