I. Ilie and the Binary Messages

Time limit: 0.3sMemory limit: 256MBInput: Output:

Ilie has a magical machine that can generate messages from binary strings.

First, Ilie gives the machine a binary string ss of length nn. The machine can then generate a message by deleting any number of characters from ss (possibly none), without changing the order of the remaining characters.

For example, if s=010s = \texttt{010}, the machine can generate the messages 0\texttt{0}, 1\texttt{1}, 01\texttt{01}, 10\texttt{10}, and several others.

The machine can also delete all characters, generating an empty message.

Ilie is only interested in distinct messages. If the same message can be generated in multiple ways, it is counted only once.

Ilie wants to choose a binary string of length nn so that his machine can generate as many distinct messages as possible.

Help Ilie find the maximum possible number of distinct messages he can generate!

Since the answer can be very large, print it modulo 998244353998244353.

Input

The only line contains a single integer nn (1≤n≤1061 \le n \le 10^6).

Output

Print a single integer: the maximum possible number of distinct messages Ilie can generate, modulo 998244353998244353.

Example

stdin

3

stdout

7

Note

The table below lists every binary string of length 33 together with all the distinct messages it can generate. Here, ε\varepsilon denotes the empty message.

ss Distinct messages Count
000 ε\varepsilon, 0, 00, 000 44
001 ε\varepsilon, 0, 1, 00, 01, 001 66
010 ε\varepsilon, 0, 1, 00, 01, 10, 010 77
011 ε\varepsilon, 0, 1, 01, 11, 011 66
100 ε\varepsilon, 0, 1, 00, 10, 100 66
101 ε\varepsilon, 0, 1, 01, 10, 11, 101 77
110 ε\varepsilon, 0, 1, 10, 11, 110 66
111 ε\varepsilon, 1, 11, 111 44

Therefore, the maximum possible number of distinct messages is 77.

Log In or Sign Up to be able to send submissions!