171k views
2 votes
Describe differences between recursive and explicit functions. Explain situations in which using a recursive or an explicit function is more efficient.

2 Answers

2 votes

Answer:

Plato

Step-by-step explanation: Recursive functions help us describe the pattern in a sequence and quickly determine the first few terms. Explicit functions allow us to find any term in the sequence without finding all the previous terms. For example, when looking for the 12th term of a sequence, a recursive function requires finding the 11 prior terms before getting the 12th term, but an explicit function requires performing only a single calculation to find the 12th term.

User Super Cool
by
4.7k points
6 votes

Step-by-step explanation:

An explicit function returns a value based only on the arguments given.

y = f(x)

__

A recursive function returns a value based on the arguments given and on other values of the function.

y = f(x, f(g(x))

User Petr Havlicek
by
6.1k points
Welcome to QAmmunity.org, where you can ask questions and receive answers from other members of our community.