1 comment (1 comment)0 reactions (0 reactions)0 assignees (0 assignees)C++3,724 forks (3,724 forks)batch import
Hacktoberfestadd codenew algorithm
Repository metrics
- Stars
- 13,462 stars (13,462 stars)
- PR merge metrics
- No merged PRs in 30d (No merged PRs in 30d)
Description
This is a(n):
Details:
The fibonnaciMemoized() function (code/mathematical-algorithms/fibonacci_number/fibonacci_memorized.swift) does not memoize values cross recursion calls.
Contributor guide
- Research direction
- Inspect the fibonacciMemoized function in fibonacci memorized.swift. The memoization dictionary is likely defined inside the function, causing it to be recreated on each call. To fix, move the dictionary outside the function or use a static variable to persist across calls.
- Tech stack
- swift
- Domain
- backend
- Issue type
- Bug
- Prerequisites
- Git