For this Question: A Tribonacci number T(n) is the sum of the preceding three elements in a series.

Calculate the value of the nth Tribonacci number modulo 1000000007. The initial three numbers of this series will be a, b and c i.e., T(1)=a, T(2)=b, T(3)=c.The only line of input contains 4 integers n, a, b, c.

Constraints
4 ≤  n ≤ 10^5
1 ≤  a, b, c ≤ 1000000000Print the result containing one integer i.e., T(n) modulo 1000000007.Input1:
5 1 2 3

Output1:
11

Input2:
4 1 1 1

Output2:
3

Explanation(might now be the optimal solution):
Input 1: 
Follow the below steps:-
T(1) = 1
T(2) = 2
T(3) = 3
T(4) = 6
T(5) = 11, I have written this Solution Code: n,a,b,c = map(int, input().split())
m = 1000000007
result = 0
while n > 3:
	result = (a%m + b%m + c%m)%m
	a = b
	b = c
	c = result
	n -= 1
print(result), In this Programming Language: Python, Now tell me if this Code is compilable or not?