Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion 01_Day_JavaScript_Refresher/01_javascript_refresher.md
Original file line number Diff line number Diff line change
Expand Up @@ -799,7 +799,8 @@ console.log(numbers.splice(0, 1)) // remove the first item

```js
const numbers = [1, 2, 3, 4, 5, 6]
console.log(numbers.splice(3, 3, 7, 8, 9)) // -> [1, 2, 3, 7, 8, 9] //it removes three item and replace three items
console.log(numbers.splice(3, 3, 7, 8, 9)) // -> [4, 5, 6] here it shows the removed items
console.log(numbers) // -> [1, 2, 3, 7, 8, 9] //it removes three item and replace three items
```

##### Adding item to an array using push
Expand Down