C. The Penguin-Gopher Shuffle
time limit per test
2 seconds
memory limit per test
256 megabytes
input
standard input
output
standard output
Desperation is magical!
— the Penguin
A penguin and a gopher were given strings $$$a$$$ and $$$b$$$, each with length $$$1\leq n \leq 1000$$$. They were tasked with transforming $$$a$$$ into $$$b$$$.

They can perform the following operation at most $$$2000$$$ times:

In a step, choose an integer $$$i$$$ satisfying $$$1\leq i\leq n$$$. Then, reverse the suffix of $$$a$$$ that starts at position $$$i$$$.

If the penguin and gopher cannot achieve their goal, output $$$-1$$$. Otherwise, output the sequence of choices of $$$i$$$ that transform $$$a$$$ into $$$b$$$.

Input

The input consists of three lines. The first line contains $$$n$$$ $$$(1\leq n\leq 1000)$$$. The second and third lines contain $$$a$$$ and $$$b$$$, respectively. $$$a$$$ and $$$b$$$ are both of length $$$n$$$, and both strings only contain lowercase Latin letters.

Output

If the task is impossible, output $$$-1$$$. Otherwise, output one line containing $$$k$$$ $$$(0\leq k\leq 2000)$$$. Then, in the next $$$k$$$ lines, output the choices of $$$i$$$ that turn $$$a$$$ into $$$b$$$.

Examples
Input
1
m
m
Output
0
Input
3
deb
fyf
Output
-1
Input
4
emog
egom
Output
1
2