// function expressions = a way to define functions as // values or variables const numbers = [1, 2, 3, 4, 5, 6]; const squares = numbers.map(function(element){ return Math.pow(element, 2); }); const cubes = numbers.map(function(element){ return Math.pow(element, 3); }); const evenNums = numbers.filter(function(element){ return element % 2 === 0; }); const oddNums = numbers.filter(function(element){ return element % 2 !== 0; }); const total = numbers.reduce(function(accumulator, element){ return accumulator + element; }); console.log(total);
@piotrmazgaj3 ай бұрын
This is my seal. I have watched the entire video, understood it, and I can explain it in my own words, thus I have gained knowledge. This is my seal.
@hunin27 Жыл бұрын
thanks bro! Can we do a big project to work on with all the things we will have learned? maybe in a week? ( also a normal project is okay. but a bigger one would be better for all of us and i think you would also get more views. also maybe do some shorts on youtube with some tips and tricks to gain subscirbers. thanks ❤