Created
July 28, 2016 14:12
-
-
Save Sylvance/b01ba476f28a3d96a891887d05d60a6d to your computer and use it in GitHub Desktop.
https://repl.it/Cgux/1 created by Sylvance
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fruits = ["Banana", "Orange", "Apple", "Mango"]; | |
fruits.push("Kiwi", "Lemon", "Pineapple"); | |
console.log(fruits); | |
fruits.unshift("Guava"); | |
console.log(fruits); | |
delete fruits[0]; | |
console.log(fruits); | |
fruits.splice(1,1); | |
console.log(fruits); | |
fruits.splice(1,1); | |
console.log(fruits); | |
fruits.splice(1,1); | |
console.log(fruits); | |
fruits.splice(1,1); | |
console.log(fruits); | |
fruits.splice(1,1); | |
console.log(fruits); | |
fruits.splice(1,1); | |
console.log(fruits); | |
fruits.splice(1,1); | |
console.log(fruits); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Native Browser JavaScript | |
>>> [ 'Banana', 'Orange', 'Apple', 'Mango', 'Kiwi', 'Lemon', 'Pineapple' ] | |
[ 'Guava', 'Banana', 'Orange', 'Apple', 'Mango', 'Kiwi', 'Lemon', 'Pineapple' ] | |
[ 'Banana', 'Orange', 'Apple', 'Mango', 'Kiwi', 'Lemon', 'Pineapple' ] | |
[ 'Orange', 'Apple', 'Mango', 'Kiwi', 'Lemon', 'Pineapple' ] | |
[ 'Apple', 'Mango', 'Kiwi', 'Lemon', 'Pineapple' ] | |
[ 'Mango', 'Kiwi', 'Lemon', 'Pineapple' ] | |
[ 'Kiwi', 'Lemon', 'Pineapple' ] | |
[ 'Lemon', 'Pineapple' ] | |
[ 'Pineapple' ] | |
[] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment