Awkward situation
Oh no! The organizing committee of the competition mixed up everything and instead of incorrect variants of conditions the poster with the inscription "BSUIROPEN" went into the shredder.
In addition to this poster in the shredder got other posters. So you have pieces, on each of which is written some text consisting of capital letters of the Latin alphabet. Now you have a new and very important mission: you need to tape some pieces together to make a new poster with the inscription "BSUIROPEN".
In fact, the organizing committee doesn't know for sure whether the poster got into the shredder or not, but you still need to make a new one (just in case). And also, it is necessary to save tape, so the new poster should be made of the minimum number of pieces.
Input
The first line specifies a single integer — the number of pieces.
The next lines specify the strings written on the chunks.
It is guaranteed that the total length of the strings does not exceed .
Output
Output a single integer — the minimum number of pieces that can be used to make a poster with the inscription "BSUIROPEN".
If such a poster cannot be made, output "" (without quotes).