UVA12613 Distinct Substring 2

Description

[problemUrl]: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=602&page=show_problem&problem=4291 [PDF](https://uva.onlinejudge.org/external/126/p12613.pdf) ![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA12613/2b20f96a76be7f9be06f40758ad7f1fd0359ee99.png)

Input Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA12613/83745cfb41c1f4147e7a7af377a8789c43e52274.png)

Output Format

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