title: Total Number Of Non Decreasing Numbers With N Digits 1
signature: function total_number_of_non_decreasing_numbers_with_n_digits_1(n)
test_code: 
  
  -- SOLUTION CODE
  -- ============================================
  PLACEHOLDER_CODE_BODY
  
  -- TESTING CODE 
  -- ============================================
  function isCorrect(actual, expected)
      if type(expected) ~= type(actual) then
          return false
      end
      
      if type(expected) == 'table' then
          for k,v_expected in pairs(expected) do
              
              if actual[k] == nil then
                  return false
              end
              local v_actual = actual[k]
              if not isCorrect(v_actual, v_expected) then
                  return false
              end
              actual[k]=nil
          end
      
          if next(actual) then 
              return false
          end
          return true
      else
          return actual == expected
      end
  end
  
  function validateSolution(actual, expected)
      return isCorrect(actual,expected)
  end
  
  function driver(n, expected)
      local exec_result;
      local status, error_msg = pcall(function () 
          exec_result=PLACEHOLDER_FN_NAME(n) 
      end)
      if status then
          if validateSolution(exec_result,expected) then
              return "PASSED"
          end
          return "FAILED"
      else
          return string.format("ERROR=%s",string.gsub(error_msg,".*:[%d]+: ",""))
      end
  end
      
  function main()
      result = driver(40, 2054455634)
      print(string.format("TEST-0...%s",result))
  
      result = driver(11, 167960)
      print(string.format("TEST-1...%s",result))
  
      result = driver(94, 2509710226100)
      print(string.format("TEST-2...%s",result))
  
      result = driver(73, 293052087900)
      print(string.format("TEST-3...%s",result))
  
      result = driver(6, 5005)
      print(string.format("TEST-4...%s",result))
  
      result = driver(73, 293052087900)
      print(string.format("TEST-5...%s",result))
  
      result = driver(58, 42757703560)
      print(string.format("TEST-6...%s",result))
  
      result = driver(40, 2054455634)
      print(string.format("TEST-7...%s",result))
  
      result = driver(64, 97082021465)
      print(string.format("TEST-8...%s",result))
  
      result = driver(66, 125595622175)
      print(string.format("TEST-9...%s",result))
  
  end
  
  main()
source_py: def total_number_of_non_decreasing_numbers_with_n_digits_1(n):
      N = 10
      count = 1
      for i in range(1, (n + 1)):
          count = int((count * ((N + i) - 1)))
          count = int((count / i))
      return count
source_cpp: long long int total_number_of_non_decreasing_numbers_with_n_digits_1(int n) {
    int N = 10;
    long long count = 1;
    for ( int i = 1;
    i <= n;
    i ++ ) {
      count *= ( N + i - 1 );
      count /= i;
    }
    return count;
  }