Javascript most useful array functions

Software engineer | Web developer | Tech Enthusiast
Search for a command to run...

Software engineer | Web developer | Tech Enthusiast
where is reduce ?? This is a hugely important (and also largely misunderstood function)
Thanks for pointing me out let me add that too
hi all in this series I'll discuss javascript string, array, math, and other inbuilt functions
charAt charAt method returns the character at the specified index in a string charCodeAt charCodeAt method returns Unicode of the character at the specified index in a string substr substr extracts the characters from a string, beginning at a speci...
JavaScript developers have long relied on Promises to manage asynchronous code smoothlyβbut what if you need to catch errors and results from both synchronous and asynchronous functions consistently? Enter Promise.try(), a brand-new addition official...

As you become more experienced with JavaScript, you may encounter some advanced topics that can help you create even more powerful and efficient code. Here are a few Javascript Topics that you must know Callback Functions Callback functions are fun...

let's first understand what continuous element in the above example, you have seen there is a repeating now I want to remove all continuous values only (not duplication) and keep 1st element of each repeating value let's see how can we achieve that ...

pow ** exponentiation operator raising the first operand to the power of the second more details explanation click here floor ~~ double bitwise not operator rounding a number towards zero more details explanation click here Wrapping up! Share thi...
charAt charAt method returns the character at the specified index in a string charCodeAt charCodeAt method returns Unicode of the character at the specified index in a string substr substr extracts the characters from a string, beginning at a speci...

push method adds one or more element at the end of an array

pop is removed the last element of the array & return that element

A shift method removes the first element from the array and all other element indexes decrease by 1

unshift method adds a new element at the beginning of an array and all other element indexes increase by 1

concat method concat two or more array and return a new array

reverse method reverses and returns the array

A slice method return portion of an array as a new array without touching the existing array it's accepted 2 optional arguments start index & end index

splice method uses to add or remove an element from an array. It's accepted 3 argument start index, delete count & new elements, it's return deleted elements.

find method return a 1st element that match with given test

filter method returns an element that matches with given test

some method returns true or false if one of the array element is pass in test condition

every method checks whether all elements in an array pass the applied test and return true if pass else false

map method creates a new array with result to apply given function to each element

sort method short array in alphabetical order. it's sort array values as strings

reduce method reduces the array to a single value from left to right

Share this blog with your friends π©πΌβπ€βπ§πΌ and developers π¨βπ» you know and let them know these
Your feedback and comments are very important to me. π