diff --git a/js-tasks/task3.js b/js-tasks/task3.js index f3d66c5..ce87a45 100644 --- a/js-tasks/task3.js +++ b/js-tasks/task3.js @@ -1,5 +1,5 @@ const map = (fn, array) => array.map((el) => fn(el)) - +//here also function square(x) { return x * x; } // возведение в квадрат -console.log(map(square, [1, 2, 3, 4])); // [1, 4, 9, 16] \ No newline at end of file +console.log(map(square, [1, 2, 3, 4])); // [1, 4, 9, 16]