Forum : Array
Brief description  about Online courses   join in Online courses
View Alok Ranjan Rai 's Profile

Array

Dear Sir,
what is array element insertion from front. and how can do it.
reply immediately
Asked by Alok Ranjan Rai | Feb 17, 2011 |  Reply now
Replies (2)
View teacher siliconindia 's Profile
Hi Alok,
You should first read the course content throughly
Feb 28, 2011
View teacher siliconindia 's Profile
Use unshift to put items on front of an array
Example:
arr = new Array("element1","element2","element3");
arr.unshift("new element");
document.write(arr);

result:
new element, element1, element2, element3
Feb 24, 2011