UVA10240 The n-Dimensional Cities

Description

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

Input Format

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

Output Format

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