Nth Tribonacci Number
Last updated
Last updated
This problem is basically Climbing Stairs but using three states instead.
As discussed in Climbing Stairs, since we only rely on the past 3
states, we can use state caching and store them as variables instead.