Keep Only Values Found in Both Arrays
Given two arrays. Use the
filter
method to return only the elements from arr1
that are also present in arr2
.Premium
JavaScript
Console