Hide

Problem I
Sweet and Smoky

The season has come for the dragons to hatch, but it seems like this year we’ve hit a rough patch. For though from the eggs dragons often arise, from none of the eggs can we hear any cries!

Indeed, the situation is quite dire. None of the eggs have even cracked, and they are long overdue! After some investigation, it was discovered that the eggs are too cold—a few insouciant dragons have been redirecting the lava from the underground lake, using it for surfing and hot baths.

\includegraphics[width=0.4\textwidth ]{TBO_Garble.png}
Figure 1: Illustration by Kyle Coate.

Without the lava, a different way will have to be found to keep the eggs warm. Garble, a dragon who secretly likes beat poetry, has a novel idea: he’s going to spit hot fire!

Many of the rules of beat poetry are unwritten and hard to pin down; however, there are some basic things we can define.

A letter is a lowercase Latin alphabet character.

A vowel is a letter equal to a, e, i, o or u.

A consonant is a letter that is not a vowel.

A word is a non-empty string consisting of letters which

  1. ends in a vowel,

  2. has no two consecutive consonants, and

  3. has no three consecutive vowels.

For example, luna, equivocate and eerie are words, while lunar, celestia and aioli are not.

By replacing exactly one letter in a word with a different one, it is often possible to construct another word. For example, we can turn abode into above by replacing exactly one letter.

The latitude of a word is the number of distinct words that can be formed by replacing exactly one letter from that word with a different one. The latitude is of great importance in poetry, as words with a higher latitude are often considered more amorphous.

Garble is now finishing his poem, but he needs to find the perfect word to make it flaming hot. He needs a word with exactly $N$ letters, whose latitude is exactly $S$.

Input

The first and only line of input contains two integers, $N$ ($1 \leq N \leq 10^6$) and $S$ ($1 \leq S \leq 10^9$), the required length and latitude, respectively.

Output

If there is no word with exactly $N$ letters and a latitude of exactly $S$, output a single line containing the string IMPOSSIBLE.

Otherwise, output a single line containing a word with exactly $N$ letters and a latitude of exactly $S$.

If there are multiple correct answers, you can output any of them.

Sample Input 1 Sample Output 1
8 80
epilogue
Sample Input 2 Sample Output 2
8 81
IMPOSSIBLE

Please log in to submit a solution to this problem

Log in