title: Wrong Answer for n = 656 Nth Fibonacci Number using Dynamic Programmin
body: <pre><code>class Solution {
    public:
    
      
      long long int nthFibonacci(long long int n){
          // code here
          //TABULATION
          long long int lookup[1001];
          lookup[0]=0;
          lookup[1]=1;
          for(long long int i=2;i&lt;=n;i++){
              lookup[i]=lookup[i-1]+lookup[i-2];
          }
          return (lookup[n]%1000000007);
      }
  };
  </code></pre>
  <p>When I submit it on GFG, it is showing that your code is giving wrong output for n=656</p>
  <p>Wrong Answer. !!!Wrong Answer</p>
  <p>Possibly your code doesn't work correctly for multiple test-cases (TCs).</p>
  <p>The first test case where your code failed:</p>
  <p>Input:
  656</p>
  <p>Its Correct output is:
  823693831</p>
  <p>And Your Code's output is:
  -584713349</p>