repl.it
@talha131/

JS Filter: Iterate Over An Array And Remove Elements

Nodejs

https://www.oncrashreboot.com/iterate-over-an-array-and-remove-elements

fork
loading
Files
  • index.js
index.js
1
2
3
4
5
const eg = [0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377, 610];

result = eg.filter(x => x < 99)

console.log(result)
node v10.16.0