You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I find it confusing that splice is used to add and also remove something from an array. I know this is a Javascript problem not a P5 problem, but the p5 documentation only describes the adding feature, not the removing.
It would be great if the documentation could include this.
splice(listName, 0, 1) // adds "0" to the listName array at position 1.
listName.splice(0, 1); //removes one item from the array at position 0.
The text was updated successfully, but these errors were encountered:
Topic
I find it confusing that splice is used to add and also remove something from an array. I know this is a Javascript problem not a P5 problem, but the p5 documentation only describes the adding feature, not the removing.
It would be great if the documentation could include this.
splice(listName, 0, 1) // adds "0" to the listName array at position 1.
listName.splice(0, 1); //removes one item from the array at position 0.
The text was updated successfully, but these errors were encountered: