Last active
June 28, 2023 23:57
-
-
Save kironroy/ad388b46a7edbbde4855485f5bc77d08 to your computer and use it in GitHub Desktop.
includes/some
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const movements3 = [200, 450, -400, 3000, -650, -130, 70, 1300]; | |
console.log(movements3); | |
// equality | |
console.log(movements3.includes(-130)); | |
// some condition | |
const anyDeposits = movements3.some(mov => mov > 1500); | |
console.log(anyDeposits); | |
// every | |
console.log(movements3.every(mov => mov > -990)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment