Skip to content
This repository was archived by the owner on Nov 30, 2022. It is now read-only.

Add recursion, ankitdobhal/Python-Scripts#1 #15

Merged
merged 1 commit into from
Oct 16, 2019
Merged

Add recursion, ankitdobhal/Python-Scripts#1 #15

merged 1 commit into from
Oct 16, 2019

Conversation

rootbid
Copy link
Contributor

@rootbid rootbid commented Oct 15, 2019

The hello-world of recursion is the Factorial. This means, you will hardly find any book or tutorial about programming languages which doesn't deal with the first and introductory example about recursive functions. Another one is the calculation of the n-th Fibonacci number. Both are well suited for a tutorial because of their simplicity but they can be easily written in an iterative way as well.

However an iterative solution for the "Towers of Hanoi" is hard to program.
This PR adds a recursive implementation of this game to these collection of helpful scripts.

@powerexploit powerexploit merged commit 7d1ad1f into powerexploit:master Oct 16, 2019
@powerexploit
Copy link
Owner

Thanks rootbid!
I am happy that you contributed about recursion

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants