chore(i18n,learn): processed translations (#53340)

Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>
This commit is contained in:
camperbot
2024-01-25 00:22:36 +05:30
committed by GitHub
parent cf1e5b8115
commit df4e5f7aca
26971 changed files with 288871 additions and 206689 deletions

View File

@@ -10,7 +10,7 @@ dashedName: remove-items-using-splice
Ok, so we've learned how to remove elements from the beginning and end of arrays using `shift()` and `pop()`, but what if we want to remove an element from somewhere in the middle? Or remove more than one element at once? Well, that's where `splice()` comes in. `splice()` allows us to do just that: **remove any number of consecutive elements** from anywhere in an array.
`splice()` can take up to 3 parameters, but for now, we'll focus on just the first 2. The first two parameters of `splice()` are integers which represent indexes, or positions, of items in the array that `splice()` is being called upon. And remember, arrays are *zero-indexed*, so to indicate the first element of an array, we would use `0`. `splice()`'s first parameter represents the index on the array from which to begin removing elements, while the second parameter indicates the number of elements to delete. For example:
`splice()` can take up to 3 parameters, but for now, we'll focus on just the first 2. The first two parameters of `splice()` are integers which represent indexes, or positions, of items in the array that `splice()` is being called upon. And remember, arrays are *zero-indexed*, so to indicate the first element of an array, we would use `0`. `splice()`'s first parameter represents the index on the array from which to begin removing elements, while the second parameter indicates the number of elements to delete. Kwa mfano:
```js
let array = ['today', 'was', 'not', 'so', 'great'];