UVA10017 The Never Ending Towers of Hanoi

Description

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

Input Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10017/358abeaf7f6673b3eba156cde5a203bcd0bb04f3.png)

Output Format

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