Give a general outline of a successful recursive function definition.

What will be an ideal response?


For a successful recursive solution to a problem, there must be:
• One or more cases in which the function accomplishes its task by using recursive call(s) to accomplish one or more smaller versions of the task.
• One or more cases in which the function accomplishes its task without the use of any recursive calls. These cases without any recursive calls are called stopping cases, or non-recursive cases, sometimes base cases.

Computer Science & Information Technology

You might also like to view...

Authentication defines which of the following? (Select all that apply.)

a. Who you are b. Where you are c. What you are d. None of the above

Computer Science & Information Technology

Just as you can block statements that depend on an if, you can also block statements that depend on a(n) ____.

A. Boolean expression B. else C. constant D. operator

Computer Science & Information Technology

What does item E in the accompanying figure show?

A. The Timeline B. The Sceneline C. The mini-timeline D. The video controller

Computer Science & Information Technology

(Checkerboard Pattern) Display the following checkerboard pattern with eight output statements, then display the same pattern using as few statements as possible.

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * What will be an ideal response?

Computer Science & Information Technology