Skip to content

Factorial of 0 and 1 must be 0.#67

Open
ameypte wants to merge 1 commit intoSoumoP:mainfrom
ameypte:patch-1
Open

Factorial of 0 and 1 must be 0.#67
ameypte wants to merge 1 commit intoSoumoP:mainfrom
ameypte:patch-1

Conversation

@ameypte
Copy link

@ameypte ameypte commented Oct 20, 2022

previously the program is showing wrong output when we enter 0 or 1 as input

previously the program is showing wrong output when we enter 0 or 1 as input
Copy link

@BhJaipal BhJaipal left a comment

Choose a reason for hiding this comment

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

This class is for fibonacci numbers, and factorial of 0 and 1 is 1 not 0
F1= F0= 0
F2=1
Fn= Fn-1+Fn+2

@BhJaipal
Copy link

Fibonacci value of 1 and 0 is 0

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.

2 participants