Udemy
    •  
    •  
    •  
    •  
    •  
    •  
    •  
    •  
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
Master JavaScript Array - Ministry of JavaScript
Rating: 4.4 out of 5(67 ratings)
2,414 students

Master JavaScript Array - Ministry of JavaScript

Subscribe to Ministry of JavaScript on Youtube for complete series on JavaScript and React.
Created byValeed Mehmood
Last updated 8/2022
English
English [Auto],

What you'll learn

  • You will be able to learn that what are Arrays in JavaScript
  • You can be able to perform any action with Arrays in JavaScript
  • You will master the coding interviews wrt Arrays
  • You will get to know the useful methods of Arrays which are being used in JavaScript development.

Course content

1 section16 lectures36m total length
  • JavaScript Array - push()0:57

    Learn how to use the push method to add a value to the end of an array, demonstrated by appending six to a numbers array.

  • JavaScript Array - unshift()2:09

    Explore the unshift method, which adds elements to the beginning of an array, with examples using numbers, strings, and objects. See console.log display the new first elements in the array.

  • JavaScript Array - shift()1:32

    Shift removes the first element of an array by calling the shift method, as shown on a numbers array one, two, three, four, five, using dot notation.

  • JavaScript Array - pop()1:09

    Learn how to remove the last element from a JavaScript array using the pop prototype method, with examples and logging to verify the change.

  • JavaScript Array - at()1:24

    Learn how to use the array prototype method at() to retrieve an element by its index, including from the end using a negative index.

  • JavaScript Array - join()1:38

    learn how the join method converts an array to a string by using a separator argument, with default comma, or custom separators like space, underscore, or empty string.

  • JavaScript Array - map()1:58

    Explain how map uses a callback to transform each array element into a new array, such as adding two, contrasting it with forEach, which does not return a new array.

  • JavaScript Array - forEach()2:22

    Learn how to use forEach to loop through an array and perform operations like summing values with a callback that receives value, index, and array, and compare to map.

  • JavaScript Array - reduce()5:18

    Explore reduce by summing an array with a callback, using an accumulator and initial zero, iterating current values to reach a final total.

  • JavaScript Array - reverse()1:20

    Discover how to reverse a JavaScript array with the prototype method reverse. The method mutates the original array, turning [6,5,4,3,2,1] into [1,2,3,4,5,6] without creating a new array.

  • JavaScript Array - some()2:43

    Discover how the JavaScript array some() method checks a condition on elements and returns true if any element matches, otherwise false; the callback uses value, index, and error.

  • JavaScript Array - findIndex()3:34

    Explore how to use the JavaScript array findIndex method with a callback to locate non-primitive values, such as objects, by a property, and compare it to indexOf for primitives.

  • JavaScript Array - flat()1:49

    Master flattening nested arrays in JavaScript by using the flat method to convert sub arrays into a single normal array, including deep flattening with flat(Infinity).

  • JavaScript Array - includes()1:18

    Learn how JavaScript includes() searches a value within an array and returns true when found. Returns false when value is not present, serves as a tool for searching primitive values.

  • JavaScript Array - every()4:37

    Explore how the JavaScript array prototype every method evaluates a callback on every element and returns true only if all elements pass, false if any fail, with active status examples.

  • JavaScript Array - filter()2:23

    Discover how the filter() method on JavaScript arrays returns all matching elements, unlike find() which returns the first match, and yields an empty array when no matches exist.

Requirements

  • Basic JavaScript

Description

Arrays plays a major role in JavaScript to learn all the useful methods in array then do watch this course. In this course we will cover all the useful methods, we will learn that how to add elements, how to remove elements, how to loop through an element, how to search an element, how to filter an element, how to slice an element from an array.

Some information about Array in JS:

The Array object, as with arrays in other programming languages, enables storing a collection of multiple items under a single variable name, and has members for performing common array operations.

In JavaScript, arrays aren't primitives but are instead Array objects with the following core characteristics:

  • JavaScript arrays are resizable and can contain a mix of different data types. (When those characteristics are undesirable, use typed arrays instead.)

  • JavaScript arrays are not associative arrays and so, array elements cannot be accessed using arbitrary strings as indexes, but must be accessed using nonnegative integers (or their respective string form) as indexes.

  • JavaScript arrays are zero-indexed: the first element of an array is at index 0, the second is at index 1, and so on — and the last element is at the value of the array's length property minus 1.

  • JavaScript array-copy operations create shallow copies. (All standard built-in copy operations with any JavaScript objects create shallow copies, rather than deep copies).


Who this course is for:

  • Beginner JavaScript Developers