UVA11472 Beautiful Numbers

Description

[problemUrl]: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=26&page=show_problem&problem=2467 [PDF](https://uva.onlinejudge.org/external/114/p11472.pdf) ![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA11472/f0fac6a9a61716dd02894d851fdd77e39624bcce.png)

Input Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA11472/78019c79f8a8e692aba6fc633aa8fcb61232435d.png)

Output Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA11472/58a8bf24e370a662486a3d49dbbb4d1875ab4265.png)