From fefb06a6b51a7699cb3986ed2d20dc0d03511055 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ca=C3=ADque=20de=20Castro=20Soares=20da=20Silva?= Date: Mon, 26 Dec 2022 17:45:05 -0300 Subject: [PATCH] Fix return of unshift method Fix return of unshift method --- book/content/part02/array.asc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/book/content/part02/array.asc b/book/content/part02/array.asc index 3bde2929..25c029ee 100644 --- a/book/content/part02/array.asc +++ b/book/content/part02/array.asc @@ -73,7 +73,7 @@ Here's an example: [source, javascript] ---- const array = [2, 5, 1]; -array.unshift(0); // ↪️ 8 +array.unshift(0); // ↪️ 4 console.log(array); // [ 0, 2, 5, 1 ] array.unshift(-2, -1); // ↪️ 6 console.log(array); // [ -2, -1, 0, 2, 5, 1 ]