Write a JavaScript code to answer the following questions:
Need help with this assignment?Get an original answer from a qualified tutor — from $10/page.
Get it written →
Assume you have created an array of pets:
var mypets = new Array();
mypets[0] = “dog”;
mypets[1] = “cat”;
mypets[2] = “goldfish”;
Write a JavaScript code to answer the following questions:
- a)Add a for loop to print out the array
- b)Write a fragment of code to insert a new pet named turtleto the end of mypets array .
- c)Write a fragment of code to removes the pet named turtle from mypets array
Get a plagiarism-free answer to this question
Send us your instructions and we’ll match you with the best writer in your subject.
- 100% human-written, zero AI
- Turnitin report included
- Confidential — we never share your data
- Free revisions & refunds