P952 [CF130E] Tribonacci numbers
普及+
题目描述

Tribonacci numbers are a sequence of numbers, defined as follows:

  • t0 = t1 = 0,
  • t2 = 1,
  • ti = ti - 1 + ti - 2 + ti - 3.

You are given n; calculate n-th tribonacci number modulo 26.

Input

The only line of input contains an integer n (1 ≤ n ≤ 1000).

Output

Output n-th tribonacci number modulo 26.

输入格式

见题面 Input 部分

输出格式

见题面 Output 部分

样例输入
4
样例输出
2