JavaScript Arrow Function => jaf;00
https://codepen.io/RGorman62/pen/eYGpwjx
A) ==============================
let add = (x, y) => x + y;
console.log(add(10, 20)); // 30;
B) ===============================
let add = function (x, y) {
return x + y;
};
console.log(add(10, 20)); // 30
C) ================================
let numbers = [4,2,6];
numbers.sort(function(a,b){
return b - a;
});
console.log(numbers); // [6,4,2] KG Sunday December 05 2021 0844 AM
Sunday December 05 2021 0824 AM