Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Conversation

@semk
Copy link

@semk semk commented Feb 23, 2014

From Python 2.5 onwards we can have conditionals like this. I think its more pythonic.

def fib(n):
    return n if n < 2 else fib(n-1) + fib(n-2)

@rafaelcanovas
Copy link

I was about to open an issue about this, a bit unfair with Python, I agree.

@mjhea0
Copy link
Owner

mjhea0 commented Apr 27, 2014

updated the readme to include this code, just in a little different manner

@mjhea0 mjhea0 closed this Apr 27, 2014
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.

3 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.