Skip to content

Conversation

@ghost
Copy link

@ghost ghost commented Mar 27, 2017

Recursion Tracing

Thanks for doing some brain yoga. You are now submitting this assignment!

Comprehension Questions

Question Answer
Did you define all the recursion terms? No, I had a hard time finding some of them and putting them into terms I understood.
How do you feel about tracing recursive problems? (good, bad, ugly, neutral) Neutral
Would you like help/follow up about recursion? It would be helpful to go over more of the definitions in class/have them included in the slides.

- Recursive Case: The function that is called within itself, should bring you closer to the base case.
- Base Case: the base case is what stops the recursion from infinite recursion
- Activation Chain/Stack - This still isn't clear to me
- Activation Record/Call - This still isn't clear to me

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An activiation record is a single call of the recursive method. So one "bubble" if you will.

- Recursion: a function that calls itself (see recursion)
- Recursive Case: The function that is called within itself, should bring you closer to the base case.
- Base Case: the base case is what stops the recursion from infinite recursion
- Activation Chain/Stack - This still isn't clear to me

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the series of recursive calls that have to be made to solve a recursive problem. So the chain of "bubbles".

- Activation Chain/Stack - This still isn't clear to me
- Activation Record/Call - This still isn't clear to me
- Infinite Recursion/Stack Overflow/Stack too deep: Recursion that would go on forever
- Tail Recursion: With each evaluation of the recursive call, the running total is updated.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is not correct - but we hadn't covered in class

@sudocrystal
Copy link

Recursion Tracing

You missed a couple definitions - ask me to explain in person if my comments don't make sense. But you did a nice job on the tracing ones!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant