#H2025H. Hrahc Likes 114514

Hrahc Likes 114514

Description

Hrahc is a 24-year-old student. He likes a number 114514\texttt{114514} very much.

Now Hrahc gets a string with numbers. He wants to know how many times the number 114514\texttt{114514} appears as a subsequence (not substring, notice that subsequence is not required to be contiguous) in the string.

Format

Input

The first line contains a single integer n(1n106)n\,(1\leq n\leq 10^6), the length of the string.

The second line contains a string of length nn, consisting of digits from 0\texttt{0} to 9\texttt{9}.

Output

Only one integer: the number of times the number 114514\texttt{114514} appears as a subsequence in the string.

Modulo 114514.

Samples

6
114514
1
7
1114514
3