UVA10024 Curling up the cube

Description

[problemUrl]: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=12&page=show_problem&problem=965 [PDF](https://uva.onlinejudge.org/external/100/p10024.pdf) ![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10024/fe3886cf116a5300a04414c3c3f47abedcc537e0.png)

Input Format

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

Output Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10024/6ddf19fe67f188aa7ce2872cb858178e2722b2b0.png)