In Minecraft, slimes are probably the most annoying enemy as once you killed a slime, it will divide into $2$ smaller slimes. Therefore, the number of slimes grows exponentially.

Alice is exhausted on killing those endless slimes! She is now fighting with a level $L$ slime in a cave.

Once a slime with level $x$ is killed:

  • It dies and disappears.
  • If $x>1$, two new slimes with level $x-1$ appears.

Help Alice to calculate how many slimes she have to kill in order to kill all the slimes.

Note that no matter what level is the slime, killing it counts as $1$ kill.

Input

The only line contains an single integer $L$, denoting the initial level of the slime.

Output

Output the number of slimes that Alice needs to kill.

Subtasks

For all test cases, $1 \le L \le 30$

Subtask Score Additional Constraints
$1$ $40$ $L \le 2$
$2$ $60$ No Additional Constraints

Sample Test Cases

Input Output
2 3
Note that when a level 1 slime is killed, no more slimes will be produced. When a level 2 slime is killed, 2 level 1 slimes is produced. When the 2 level 1 slimes is killed, no more slime exists. The total count is 3.
Click to copy.

Scoring: Per Subtask
Authored by s22f26
Appeared in 2026 Mini Comp 5 (Pre-HKSC)