Codeforces Round 302 (Div. 2)
A
Set of Strings
Codeforces
1100
原题
←B →
翻译中…

You are given a string $*q*$. A sequence of $*k*$ strings $*s*_{1}, *s*_{2}, ..., *s*_{*k*}$ is called beautiful, if the concatenation of these strings is string $*q*$ (formally, $*s*_{1} + *s*_{2} + ... + *s*_{*k*} = *q*$) and the first characters of these strings are distinct.

翻译中…

Find any beautiful sequence of strings or determine that the beautiful sequence doesn't exist.

翻译中…

Input

翻译中…

The first line contains a positive integer $*k*$ ($1 ≤ *k* ≤ 26$) — the number of strings that should be in a beautiful sequence.

翻译中…

The second line contains string $*q*$, consisting of lowercase Latin letters. The length of the string is within range from $1$ to $100$, inclusive.

翻译中…

Output

翻译中…

If such sequence doesn't exist, then print in a single line "NO" (without the quotes). Otherwise, print in the first line "YES" (without the quotes) and in the next $*k*$ lines print the beautiful sequence of strings $*s*_{1}, *s*_{2}, ..., *s*_{*k*}$.

翻译中…

If there are multiple possible answers, print any of them.

翻译中…

Note

翻译中…

In the second sample there are two possible answers: ${"*aaaca*", "*s*"}$ and ${"*aaa*", "*cas*"}$.

翻译中…

样例

Input #1
1
abca
Output #1
YES
abca
InputCopy OutputCopy
Input #2
2
aaacas
Output #2
YES
aaa
cas
InputCopy OutputCopy
Input #3
4
abc
Output #3
NO
InputCopy OutputCopy
题目信息
题号
544A
时间限制
1 s
内存限制
256 MB
标签
模拟
字符串

题面与样例版权归 Codeforces 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。