mirror of
https://github.com/trekhleb/javascript-algorithms.git
synced 2025-07-10 13:37:56 +08:00
Code style fixes.
This commit is contained in:
@ -18,7 +18,7 @@ export default function fibonacci(n) {
|
||||
|
||||
while (iterationsCounter) {
|
||||
currentValue += previousValue;
|
||||
previousValue = (currentValue - previousValue);
|
||||
previousValue = currentValue - previousValue;
|
||||
|
||||
fibSequence.push(currentValue);
|
||||
|
||||
|
@ -16,7 +16,7 @@ export default function fibonacciNth(n) {
|
||||
|
||||
while (iterationsCounter) {
|
||||
currentValue += previousValue;
|
||||
previousValue = (currentValue - previousValue);
|
||||
previousValue = currentValue - previousValue;
|
||||
|
||||
iterationsCounter -= 1;
|
||||
}
|
||||
|
Reference in New Issue
Block a user