class Solution:
def findDifference(self, nums1: List[int], nums2: List[int]) -> List[List[int]]:
nums1 = set(nums1)
nums2 = set(nums2)
return nums1 - nums2, nums2 - nums1
'CS > 알고리즘' 카테고리의 다른 글
[Leetcode] 844. Backspace String Compare (0) | 2023.05.05 |
---|---|
[Leetcode] 82. Remove Duplicates from Sorted List II (0) | 2023.05.04 |
[Leetcode] 1491. Average Salary Excluding the Minimum and Maximum Salary (0) | 2023.05.02 |
[Leetcode] 1822. Sign of the Product of an Array (0) | 2023.05.02 |
[Leetcode] 121. Best Time to Buy and Sell Stock (0) | 2023.05.02 |