타겟과 다른 두 수의 합으로 표현 -> 타겟을 제외한 temp 리스트 생성
1) Two Pointers 탐색
2) Brute Force 탐색
n = int(input())
nums = list(map(int, input().split()))
nums.sort()
count = 0
for i in range(n):
target = nums[i]
temp = nums[:i] + nums[i+1:]
left = 0
right = len(temp) - 1
while left < right:
total = temp[left] + temp[right]
if total == target:
count += 1
break
elif total < target:
left += 1
elif total > target:
right -= 1
print(count)