Problem: Kolya has a string s of length n consisting of lowercase and uppercase Latin letters and digits.

He wants to rearrange the symbols in s and cut it into the minimum number of parts so that each part is a palindrome and all parts have the same lengths. A palindrome is a string which reads the same backward as forward, such as madam or racecar.

Your task is to help Kolya and determine the minimum number of palindromes of equal lengths to cut s into, if it is allowed to rearrange letters in s before cuttings.

Input

The first line contains an integer n (1 ≤ n ≤ 4·105) — the length of string s.

The second line contains a string s of length n consisting of lowercase and uppercase Latin letters and digits.

Output

Print to the first line an integer k — minimum number of palindromes into which you can cut a given string.

Print to the second line k strings — the palindromes themselves. Separate them by a space. You are allowed to print palindromes in arbitrary order. All of them should have the same length.

Examples

Input

6
aabaac


Output

2
aba aca 

Input

8
0rTrT022


Output

1
02TrrT20 

Input

2
aA


Output

2
a A 

Solution (in PYTHON3):

Solution:
import sys
from collections import Counter


def gen(counter, skip):
    for c, n in counter:
        has = n // 2
        if skip > has:
            skip -= has
            has = 0
        elif skip > 0:
            has -= skip
            skip = 0
        for i in range(has):
            yield c


def gen_o(counter, take):
    for c, n in counter:
        for i in range(n % 2):
            yield c
    for c, n in counter:
        has = (n // 2) * 2
        if take > has:
            take -= has
        elif take > 0:
            has = take
            take = 0
        for i in range(has):
            yield c


N = int(next(sys.stdin))

s = next(sys.stdin).strip()
c = Counter(s)

even = 0
odd = 0
items = list(c.items())
for _, n in items:
    even += n // 2
    odd += n % 2
generator = gen(items, 0)
generator_o = gen_o(items, 0)

odd_c = odd
if odd == 0:
    print(1)
    front = [next(generator) for i in range(len(s) // 2)]
    fs = "".join(front)
    print(fs + fs[::-1])
else:
    skip = 0
    while even != 0 and even % odd != 0:
        skip += 1
        odd += 2
        even -= 1
    generator = gen(items, skip)
    generator_o = gen_o(items, skip * 2)
    print(odd)
    per = even // odd
    strs = []
    for i in range(odd):
        front = [next(generator) for i in range(per)]
        fs = "".join(front)
        strs.append(fs + next(generator_o) + fs[::-1])
    print(" ".join(strs))