title: Nth Non Fibonacci Number
signature: function nthNonFibonacciNumber(n) {
test_code: 
  
  // SOLUTION CODE
  // ============================================
  PLACEHOLDER_CODE_BODY
  
  // TESTING CODE 
  // ============================================
  function convertToString(value) {
      return JSON.stringify(value, function (key, val) {
          if (val instanceof Set) {
              return Array.from(val);
          } return val;});
  }
  
  function validateSolution(actual, expected){
      return convertToString(actual)===convertToString(expected);
  }
  
  function driver(n, expected){
      try{
          if (validateSolution(PLACEHOLDER_FN_NAME(n),expected)){
              return "PASSED";
          }
          return "FAILED";
      } catch (error) {
        return error.name;
      }
      
  }
      
  function main(){
    let result = '';
    result = driver(76, 85);
    console.log(`TEST-0...${result}`);
  
    result = driver(91, 101);
    console.log(`TEST-1...${result}`);
  
    result = driver(62, 71);
    console.log(`TEST-2...${result}`);
  
    result = driver(65, 74);
    console.log(`TEST-3...${result}`);
  
    result = driver(83, 93);
    console.log(`TEST-4...${result}`);
  
    result = driver(57, 66);
    console.log(`TEST-5...${result}`);
  
    result = driver(76, 85);
    console.log(`TEST-6...${result}`);
  
    result = driver(6, 11);
    console.log(`TEST-7...${result}`);
  
    result = driver(2, 6);
    console.log(`TEST-8...${result}`);
  
    result = driver(86, 96);
    console.log(`TEST-9...${result}`);
  
    process.exit(0);
  };
  
  if (require.main === module) {
    main();
  }
source_py: def nth_non_fibonacci_number(n):
      prevPrev = 1
      prev = 2
      curr = 3
      while (n > 0):
          prevPrev = prev
          prev = curr
          curr = (prevPrev + prev)
          n = (n - ((curr - prev) - 1))
      n = (n + ((curr - prev) - 1))
      return (prev + n)
source_cpp: int nth_non_fibonacci_number(int n) {
    int prevPrev = 1, prev = 2, curr = 3;
    while ( n > 0 ) {
      prevPrev = prev;
      prev = curr;
      curr = prevPrev + prev;
      n = n - ( curr - prev - 1 );
    }
    n = n + ( curr - prev - 1 );
    return prev + n;
  }