Movatterモバイル変換


[0]ホーム

URL:


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

Sign up
Appearance settings

Solution 3 to Climbing Stairs Problem#200

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
hiteshskp wants to merge1 commit intokamyu104:master
base:master
Choose a base branch
Loading
fromhiteshskp:patch-4

Conversation

@hiteshskp
Copy link
Contributor

As 1 <= n <= 45 we can use Binet’s Formula (Fibonacci closed form) PS: this won't work for n>70 or 100 The "climb stairs" problem is equivalent to computing the nth Fibonacci number (with a slight index shift), where: F(0) = 0
F(1) = 1
F(n) = F(n-1) + F(n-2)
The number of ways to climb n stairs is the (n + 1)th Fibonacci number.

As 1 <= n <= 45 we can use Binet’s Formula (Fibonacci closed form) PS: this won't work for n>70 or 100The "climb stairs" problem is equivalent to computing the nth Fibonacci number (with a slight index shift), where:F(0) = 0F(1) = 1F(n) = F(n-1) + F(n-2)The number of ways to climb n stairs is the (n + 1)th Fibonacci number.
@hiteshskp
Copy link
ContributorAuthor

@kamyu104 need some approvals PLEASE

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

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

@hiteshskp

[8]ページ先頭

©2009-2025 Movatter.jp