From 2fb57471422edffa96ee5dbcb5484b3a364d4e68 Mon Sep 17 00:00:00 2001 From: Vusal Date: Wed, 3 Jan 2024 19:02:59 +0400 Subject: [PATCH] made first contribution --- index.html | 52 ++++++++++++++++++++++++++-------------------------- index.js | 24 ++++++++++++++---------- 2 files changed, 40 insertions(+), 36 deletions(-) diff --git a/index.html b/index.html index f207a2f..66fdfc5 100644 --- a/index.html +++ b/index.html @@ -1,33 +1,33 @@ - - - - - + + + + + Document - - + + - +
-

Hello!

-
-
-
-
-
-
-
-
-
-
+

Hello!

+
+
+
+
+
+
+
+
+
+
- - \ No newline at end of file + + diff --git a/index.js b/index.js index 5248e01..b9c3643 100644 --- a/index.js +++ b/index.js @@ -1,18 +1,22 @@ - array = [1, 2, 3]; -if (array){ - for(array = array.length; array <= 10; array++){ -console.log(array) - } +if (array) { + for (array = array.length; array <= 10; array++) { + console.log(array); + } } - -op = [1, 2, 3] +op = [1, 2, 3]; num = " over here!"; -if (op === 1, 2, 3){ - for (op = 0; op <= 100; op++){ +if ((op === 1, 2, 3)) { + for (op = 0; op <= 100; op++) { console.log(op + num); -} + } } +// array methods + +const newArray = [1, 2, 3, 4]; + +const mutatedArray = newArray.map((num) => num * 2); +console.log(mutatedArray);