Concatenation of Three Palindromes#8251

Concatenation of Three Palindromes

1 second
256 megabytes
Hard

Given a string of length , determine whether can be expressed as a concatenation of three palindromes.

Input

The first line contains a natural number (n \leq 10000). The second line contains the string (|s| = n).

Output

If the string cannot be represented as a concatenation of three palindromes, output "NO". Otherwise, print "YES" on the first line, and on the next line print the three palindromes, separated by spaces, whose concatenation forms . If there are multiple solutions, any valid set of palindromes can be provided.

Examples

Example 1

Loading
Loading