[BOJ / Python] 1269 대칭 차집합

도니·2023년 4월 20일

BOJ / Python

목록 보기
99/105
post-thumbnail

문제

백준 1269 대칭 차집합

코드

n, m = map(int, input().split())
a = set(map(int, input().split()))
b = set(map(int, input().split()))
print(len(a - b) + len(b - a))

코드 설명

💡 집합 자료형의 차집합 이용하기!

profile
Where there's a will, there's a way

0개의 댓글