Skip to content

Commit 4e2d639

Browse files
author
chengruilin
committed
fix: correct createMemo.md
1 parent 9c8e093 commit 4e2d639

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Diff for: docs/createMemo.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ which receives the same arguments and returns the same result as the original fu
1010
import {createMemo} from 'react-use';
1111

1212
const fibonacci = n => {
13-
if (n === 0) return 1;
14-
if (n === 1) return 2;
13+
if (n === 0) return 0;
14+
if (n === 1) return 1;
1515
return fibonacci(n - 1) + fibonacci(n - 2);
1616
};
1717

0 commit comments

Comments
 (0)