349. Intersection of Two Arrays
Easy
Given two integer arrays nums1
and nums2
, return an array of their intersection. Each element in the result must be unique and you may return the result in any order.
Example 1:
Example 2:
Constraints:
1 <= nums1.length, nums2.length <= 1000
0 <= nums1[i], nums2[i] <= 1000
解題
解題
Runtime: 3 ms, faster than 86.21%
Memory Usage: 2.9 MB, less than 88.97%
Last updated