Skip to content

Commit

Permalink
fix: mismatch between code and return value (#37120)
Browse files Browse the repository at this point in the history
  • Loading branch information
jolka-ef authored Dec 6, 2024
1 parent b7b0b7c commit 75c5e27
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,7 @@ const isEven = (x) => x % 2 === 0;
console.log(fibonacci().some(isEven)); // true

const isNegative = (x) => x < 0;
const isPositive = (x) => x > 0;
console.log(fibonacci().take(10).some(isPositive)); // false
console.log(fibonacci().take(10).some(isNegative)); // false
console.log(fibonacci().some(isNegative)); // Never completes
```

Expand Down

0 comments on commit 75c5e27

Please sign in to comment.