Which method adds one or more elements to the end of an array and returns the new length?

JavaScript Associate Easy

JavaScript Associate — Easy

Which method adds one or more elements to the end of an array and returns the new length?

Key points

  • push() adds elements to the end of an array
  • push() returns the new length of the array
  • unshift() adds elements to the beginning of an array
  • concat() merges arrays without modifying the original arrays

Ready to go further?

Related questions