fix(mathutil): honour Fibonacci seeds at the first positions (#362)

This commit is contained in:
Yusuf Efe authored and GitHub committed 2026-10-23 20:57:07 +08:00
1 parent a296281408
commit 172712df30
2 files changed
+8 -2

No files matched your search

+4 -2
View File
@@ -35,8 +35,10 @@ func Fibonacci(first, second, n int) int {
if n <= 0 {
return 0
}
if n < 3 {
return 1
if n == 1 {
return first
} else if n == 2 {
return second
} else if n == 3 {
return first + second
} else {