I couldn't find my previous resource but this has an example of recursion implementing memoization to reduce Big O complexity. It may be that it is possible to memoize the iterative approach as well and it's just easier to utilize recursions use of holding memory to make it easier or more efficient. stackoverflow.com/questions/134400...
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
I couldn't find my previous resource but this has an example of recursion implementing memoization to reduce Big O complexity. It may be that it is possible to memoize the iterative approach as well and it's just easier to utilize recursions use of holding memory to make it easier or more efficient.
stackoverflow.com/questions/134400...