This commit is contained in:
codevadym 2025-01-31 22:03:46 +01:00
parent 259c013d78
commit a27155555f
5 changed files with 22 additions and 3 deletions

View File

@ -8,7 +8,7 @@
*/
var massive = [1111, 'test', true]
var array = [1111, 'test', true]
console.log(massive[0])
console.log(massive.length)
console.log(array[0])
console.log(array.length)

View File

@ -8,3 +8,9 @@
*
* 4. Выведите в консоль измененный массив
*/
var array = [1, true, null]
console.log(array)
array[1] = false
console.log(array)

View File

@ -5,3 +5,9 @@
* 2. Используя один из методов массивов, переберите все элементы
* и выведите каждый элемент в консоль
*/
var array = [1, 2, 3, 4]
array.forEach((item) => {
console.log(item)
})

View File

@ -6,3 +6,6 @@
*
* 3. Выведите в консоль длину результирующего массива
*/
var array = [1, 2, 3]
array.push(4, 5, 6)
console.log(array)

View File

@ -4,3 +4,7 @@
*
* 2. Выведите значение в консоль
*/
var timeInMsec = Date.now()
console.log(timeInMsec)