If tutorials available on this website are helpful for you, please whitelist this website in your ad blocker😭 or Donate to help us ❤️ pay for the web hosting to keep the website running.
push() method का use Array में new element को insert करने के लिए किया जाता है। New element Array के end में insert होता है।
array.push(element1, element2, ... , elementn);
element | required : Array में insert की जाने वाली value है। आप एक साथ कई elements को insert कर सकते हैं।
Return Value : element(s) insert करने के बाद Array की length return करता है।
File : js_array_push.html
<!DOCTYPE html>
<html>
<body>
<script>
var arr=["PHP" , "jQuery"];
arr.push("JavaScript");
document.writeln(arr);
</script>
</body>
</html>
PHP,jQuery,JavaScript
Hi ! My name is Rahul Kumar Rajput. I'm a back end web developer and founder of learnhindituts.com. I live in Uttar Pradesh (UP), India and I love to talk about programming as well as writing technical tutorials and tips that can help to others.
Get connected with me. :) LinkedIn Twitter Instagram Facebook