Harryxun/GPT-100-sft-dataset huggingface dataset:
Problem p02761 (python)

Fixed submission:
n, m = map(int, input().split())

d={}

for i in range(m):
    s, c = map(int, input().split())
    if s == 1 and c == 0 and n != 1:
        print(-1)
        exit()
    elif s not in d:
        d[s] = c
    else:
        if d[s] != c:
            print(-1)
            exit()
if 1 not in d and n != 1:
    d[1] = 1
if 1 not in d and n == 1:
    d[1]=0
    
for i in range(2, n+1):
    if i not in d:
        d[i] = 0
ans = 0
for i in range(1, n+1):
    ans += d[i] * pow(10, n-i)
print(ans)

Buggy submission (verdict: Runtime Error):
n, m = map(int, input().split())

d={}

for i in range(m):
    s, c = map(int, input().split())
    if s == 1 and c == 0:
        print(-1)
        eixt()
    elif s not in d:
        d[s] = c
    else:
        if d[s] != c:
            print(-1)
            exit()
if 1 not in d:
    d[1] = 1
for i in range(2, n+1):
    if i not in d:
        d[i] = 0
ans = 0
for i in range(1, n+1):
    ans += d[i] * pow(10, n-i)
print(ans)
Problem p02783 (python)

Fixed submission:
import math
n, m = map(int, input().split())
print(math.ceil(n/m))

Buggy submission (verdict: Runtime Error):
import math
n, m = int(input().split())
print(math.ceil(n/m))

Buggy submission (verdict: Runtime Error):
import math
n, m = input().split()
print(math.ceil(n/m))
Problem p02789 (python)

Fixed submission:
n, m=input().split()
if n==m:
    print("Yes")
else:
    print("No")

Buggy submission (verdict: Runtime Error):
n, m=input().split
if n==m:
    print("AC")
else:
    print("WA")
Problem p02802 (python)

Fixed submission:
n, m=map(int, input().split())
a=set()
d={}
pena=0
for i in range(m):
    p, s=input().split()
    if s=="AC" and int(p) not in a:
        a.add(int(p))
        if p in d:
            pena+=d.pop(p)
    else:
        if p in d:
            d[p]+=1
        else:
            d[p]=1
print(len(a), pena)

Buggy submission (verdict: Runtime Error):
n, m=map(int, input().split())
a=set()
d={}
pena=0
for i in range(m):
    p, s=input().split()
    if s=="AC":
        a.add(int(p))
        pena+=d.pop(p)
    else:
        if p in d:
            d[p]+=1
        else:
            d[p]=1
print(len(a), pena)
Problem p02917 (python)

Fixed submission:
n = int(input())
b = list(map(int, input().split()))
ans = b[0] + b[-1]
for i in range(n-2):
    ans += min(b[i], b[i+1])
print(ans)

Buggy submission (verdict: Runtime Error):
n = int(input())
b = list(map(int, input().split()))
ans = b[0] + b[-1]
for i in range n-2:
    ans += min(b[i], b[i+1])
print(ans)
Problem p02600 (python)

Fixed submission:
import sys
read = sys.stdin.readline
import time
import math
import itertools as it
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N = int(input())
if 400 <= N and N <= 599:
    ans = 8
elif 600 <= N and N <= 799:
    ans = 7
elif 800 <= N and N <= 999:
    ans = 6
elif 1000 <= N and N <= 1199:
    ans = 5
elif 1200 <= N and N <= 1399:
    ans = 4
elif 1400 <= N and N <= 1599:
    ans = 3
elif 1600 <= N and N <= 1799:
    ans = 2
elif 1800 <= N and N <= 1999:
    ans = 1


print(ans)



# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
import sys
read = sys.stdin.readline
import time
import math
import itertools as it
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N, K = inpl()
A = inpl()
for i in range(K, N):
    if A[i] > A[i-K]:
        print('Yes')
    else:
        print('No')

# -----------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
import sys
read = sys.stdin.readline
import time
import math
import itertools as it
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N = int(input())
if 400 <= N and N <= 599:
    ans = 8
elif 600 <= N and N <= 799:
    ans = 7
elif 800 <= N and N <= 99:
    ans = 6
elif 1000 <= N and N <= 1199:
    ans = 5
elif 1200 <= N and N <= 1399:
    ans = 4
elif 1400 <= N and N <= 1599:
    ans = 3
elif 1600 <= N and N <= 1799:
    ans = 2
elif 1800 <= N and N <= 1999:
    ans = 1


print(ans)



# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)
Problem p02630 (python)

Fixed submission:
import sys
import time
import math
st = time.perf_counter()
def inpl():
    return list(map(int, input().split()))
# ------------------------------

N = int(input())
nl = [0] * 100100
ls = inpl()
ans = 0
for i in ls:
	nl[i] += 1
	ans += i
M = int(input())
for _ in range(M):
	a, b = map(int, input().split())
	ans = ans - (nl[a] * a) + (nl[a] * b)
	nl[b] += nl[a]
	nl[a] = 0
	print(ans)

# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
import sys
import time
import math
st = time.perf_counter()
def inpl():
    return list(map(int, input().split()))
# ------------------------------

N = int(input())
nl = [0] * 10101
ls = inpl()
ans = 0
for i in ls:
	nl[i] += 1
	ans += i
M = int(input())
for _ in range(M):
	a, b = map(int, input().split())
	ans = ans - (nl[a] * a) + (nl[a] * b)
	nl[b] += nl[a]
	nl[a] = 0
	print(ans)

# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
import sys
import time
import math
st = time.perf_counter()
def inpl():
    return list(map(int, input().split()))
# ------------------------------

N = int(input())
nl = [0] * 10101
ls = inpl()
ans = 0
for i in ls:
	nl[i] += 1
	ans += i
M = int(input())
for _ in range(M):
	a, b = map(int, input().split())
	ans = ans - nl[a] * a + nl[b] * b
	nl[b] += nl[a]
	nl[a] = 0
	print(ans)

# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)
Problem p02642 (python)

Fixed submission:
import sys
read = sys.stdin.readline
import time
import math
import itertools as it
def inp():
    return int(input())
def inpl():
    return list(map(int, input().split()))
start_time = time.perf_counter()
# ------------------------------

N = inp()
A = inpl()
A.sort()
dp = [False] * 1001001
nt = -1

for i in A:
    if i != nt:
        dp[i] = True
    else:
        dp[i] = False
    nt = i

ans = 0
mx = A[N-1]
nt = -1
for i in A:
    if dp[i]:
        ans += 1
    if i == nt:
        continue
    nt = i
    j = i
    while j <= mx:
        dp[j] = False
        j += i

print(ans)

# -----------------------------
end_time = time.perf_counter()
print('time:', end_time-start_time, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
import sys
read = sys.stdin.readline
import time
import math
import itertools as it
def inp():
    return int(input())
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N = inp()
A = inpl()
A.sort()
dp = [False] * 1001001
nt = -1
for i in A:
    if i != nt:
        dp[i] = True
    else:
        dp[i] = False
    nt = i

ans = 0
mx = A[N-1]
for i in A:
    if dp[i]:
        ans += 1
        j = i
        while j <= 1001001:
            dp[j] = False
            j += i
print(ans)

# -----------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)
Problem p02658 (python)

Fixed submission:
def main():
  n = int(input())
  ls = list(map(int, input().split()))
  if 0 in ls:
    print(0)
    return
  ans = 1
  for l in ls:
    ans *= l
    if ans > 1000000000000000000:
      print(-1)
      return
  print(ans)
  
main()

Buggy submission (verdict: Runtime Error):
n = int(input())
ls = list(map(int, input().split()))
if 0 in ls:
  print(0)
  return
ans = 1
for l in ls:
  ans *= l
  if ans > 1000000000000000000:
    print(-1)
    return
print(ans)

Buggy submission (verdict: Runtime Error):
n = int(input())
ls = list(map(int, input().split()))
ans = 1
for l in ls:
  ans *= l
  if ans > 1e18:
    print(-1)
    return
print(ans)

Buggy submission (verdict: Runtime Error):
ls = list(map(int, input().split()))
ans = 1
for l in ls:
  ans *= l
  if ans > 1e18:
    print(-1)
    return
print(ans)
Problem p02660 (python)

Fixed submission:
import sys
import time
st = time.perf_counter()
# ------------------------------


def prime_decomposition(n):
    i = 2
    table = []
    while i * i <= n:
        while n % i == 0:
            n //= i
            table.append(i)
        i += 1
    if n > 1:
        table.append(n)
    return table

from itertools import groupby
N = int(input())
P = prime_decomposition(N)
ans = 0
for k, g in groupby(P):
    n = len(list(g))
    for i in range(1, 10000000):
        n -= i
        if n >=0:
            ans += 1
        else:
            break
print(ans)

        
        



# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):

def prime_decomposition(n):
    i = 2
    table = []
    while i * i <= n:
        while n % i == 0:
            n //= i
            table.append(i)
        i += 1
    if n > 1:
        table.append(n)
    return table

from itertools import groupby
N = int(input())
P = prime_decomposition(N)
ans = 0
for k, g in groupby(P):
    n = len(g)
    for i in range(1, 10000000):
        n -= i
        if n >=0:
            ans += 1
        else:
            break
print(ans)
Problem p02684 (python)

Fixed submission:
import sys
import time
st = time.perf_counter()
# ------------------------------

N, K = map(int, input().split())
A = list(map(int, input().split()))
A = [i-1 for i in A]

cnt = [-1] * N
cnt[0] = 0
now = 0
for i in range(1, 1001001001):
    now = A[now]
    if cnt[now] == -1:
        cnt[now] = i
    else:
        circle = i - cnt[now]
        t = cnt[now]
        break
if K - t > 0:
    amari = (K - t) % circle
    for _ in range(amari):
        now = A[now]
else:
    now = 0
    for i in range(K):
        now = A[now]
print(now + 1)

# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i=0; i<(n); i++)
#define INF 1001001001
using ll = long long;
using dd = long double;

const int D = 60;
const int MAX_N = 20005;
int to[D][MAX_N];


int main() {
    int n;
    ll k;
    cin >> n >> k;
    rep(i,n) {
        cin >> to[0][i];
        to[0][i]--;
    }

    rep(i,D-1)rep(j,n) {
        to[i+1][j] = to[i][to[i][j]];
    }

    int v = 0;
    for (int i = D-1; i >= 0; --i) {
        ll l = 1ll<<i;
        if (l <= k) {
            v = to[i][v];
            k -= l;
        }
    }
    cout << v+1 << endl;
    
    return 0;
}

Buggy submission (verdict: Runtime Error):
import sys
import time
st = time.perf_counter()
# ------------------------------

N, K = map(int, input().split())
A = list(map(int, input().split()))
A = [i-1 for i in A]

cnt = [-1] * N
cnt[0] = 0
now = 0
for i in range(1, 1001001001):
    now = A[now]
    if cnt[now] == -1:
        cnt[now] = i
    else:
        circle = i - cnt[now]
        t = cnt[now]
        break
if K - t > 0:
    amari = (K - t) % circle
    for _ in range(amari):
    now = A[now]
else:
    now = 0
    for i in range(K):
        now = A[now]
print(now + 1)

# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)
Problem p02687 (python)

Fixed submission:
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**6)

def inp():
    return int(input())
def inps():
    return input().rstrip()
def inpl():
    return list(map(int, input().split()))
def _debug(obj):
    print(obj, file=sys.stderr)

# import decimal
# from decimal import Decimal
# decimal.getcontext().prec = 10

# from heapq import heappush, heappop, heapify
# import math
# from math import gcd
# import itertools as it
# import collections
# from collections import deque 

# ---------------------------------------

s = inps()
print("ARC" if s == "ABC" else "ABC")

Buggy submission (verdict: Runtime Error):
a = input()
if a = 'ABC':
  print('ARC')
else:
  print('ABC')
Problem p02714 (python)

Fixed submission:
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**6)

def inp():
    return int(input())
def inps():
    return input().rstrip()
def inpl():
    return list(map(int, input().split()))
def _debug(obj):
    print(obj, file=sys.stderr)

# import decimal
# from decimal import Decimal
# decimal.getcontext().prec = 10

# from heapq import heappush, heappop, heapify
# import math
# from math import gcd
# import itertools as it
# import collections
# from collections import deque 

# ---------------------------------------

N = inp()
S = inps()

r = []
g = []
b = []

for i in range(N):
    if S[i] == "R":
        r.append(i)
    if S[i] == "G":
        g.append(i)
    if S[i] == "B":
        b.append(i)

ans = 0
for i in r:
    for j in g:
        m = i
        n = j
        if m > n:
            m, n = n, m
        sa = abs(m - n)
        ans += len(b)
        if m - sa >= 0 and S[m - sa] == "B":
            ans -= 1
        if n + sa < N and S[n + sa] == "B":
            ans -= 1
        if sa % 2 == 0 and S[m + sa//2] == "B":
            ans -= 1
print(ans)

Buggy submission (verdict: Runtime Error):
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**6)

def inp():
    return int(input())
def inps():
    return input().rstrip()
def inpl():
    return list(map(int, input().split()))
def _debug(obj):
    print(obj, file=sys.stderr)

# import decimal
# from decimal import Decimal
# decimal.getcontext().prec = 10

# from heapq import heappush, heappop, heapify
# import math
# from math import gcd
# import itertools as it
# import collections
# from collections import deque 

# ---------------------------------------

N = inp()
S = inps()

r = []
g = []
b = []

for i in range(N):
    if S[i] == "R":
        r.append(i)
    if S[i] == "G":
        g.append(i)
    if S[i] == "B":
        b.append(i)

ans = 0
for i in r:
    for j in g:
        for k in b:
            if abs(i - j) != abs (j - k) 
                    and abs(i - j) != abs (i - k) 
                    and abs(i - k) != abs (j - k):
                ans += 1
print(ans)
Problem p02761 (python)

Fixed submission:
import sys
import time
import math
import itertools as it
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N, M = inpl()
dp = [-1] * N
for _ in range(M):
    s, c = inpl()
    s -= 1
    if dp[s] not in [-1, c]:
        print(-1)
        sys.exit()
    dp[s] = c
for i in range(N):
    if N == 1:
        if dp[i] == -1:
            print(0, end='')
        else:
            print(dp[i], end='')
    else:
        if i == 0:
            if dp[i] == -1:
                print(1, end='')
            elif dp[i] == 0:
                print(-1)
                sys.exit()
            else:
                print(dp[i], end='')
        else:
            if dp[i] == -1:
                print(0, end='')
            else:
                print(dp[i], end='')
                
print()
# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
import sys
import time
import math
import itertools as it
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N, M = inpl()
dp = [-1] * N
for _ in range(M):
    s, c = inpl()
    s -= 1
    if dp[s] not in [-1, c]:
        print(-1)
        sys.exit()
    dp[s] = c
for i in range(N):
    if N == 1:
        if dp[i] == -1:
            print(0, end='')
        else:
            print(dp[i], end='')
    else:
        if i == 0:
            if dp[i] == -1:
                print(1, end='')
            elif dp[i] == 0
                print(-1)
                sys.exit()
            else:
                print(dp[i], end='')
        else:
            if dp[i] == -1:
                print(0, end='')
            else:
                print(dp[i], end='')
                
print()
# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
import sys
import time
import math
import itertools as it
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N, M = map(int, input().split())
s = [0] * M
c = [0] * M
for i in range(M):
	s[i], c[i] = map(int, input().split())
ls = [-1] * N
for i in range(M):
	if ls[s[i]-1] == -1 or ls[s[i]-1] == c[i]:
		ls[s[i]-1] = c[i]
	else:
		print(-1)
		sys.exit()

if ls[0] == 0:
	print(-1)
	sys.exit()
for i in range(M):
	if i == 0 and ls[i] == -1:
		print(1, end='')
	elif ls[i] == -1:
		print(0, end='')
	else:
		print(ls[i], end ='')
print()



# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)
Problem p02802 (python)

Fixed submission:
import sys
import time
import math
import itertools as it
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N, M = inpl()
ac = [False] * (N+10)
wa = [0] * (N+10)

for _ in range(M):
    p, S = input().split()
    p = int(p)
    if S == 'WA':
        if not ac[p]:
            wa[p] += 1
    else:
        ac[p] = True

a = 0
w = 0
for i in range(N+10):
    if ac[i]:
        a += 1
        w += wa[i]

print(a, w)

# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
import sys
import time
import math
import itertools as it
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N, M = inpl()
dp = [False] * (N+10)
ac = 0
wa = 0
for _ in range(M):
    p, S = input().split()
    p = int(p)
    if S == 'WA':
        if !dp[p]:
            wa += 1
    else:
        if !dp[p]:
            ac += 1
            dp[p] = True
print(ac, wa)


# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)
Problem p02813 (python)

Fixed submission:
import sys
import time
import math
import itertools as it
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N = int(input())
P = inpl()
Q = inpl()
ls = P.copy()
ls.sort()
cnt = 0
a = 0
b = 0
for l in it.permutations(ls):
    cnt += 1
    l = list(l)
    if P == l:
        a = cnt
    if Q == l:
        b = cnt
print(abs(a - b))
# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
import sys
import time
import math
import itertools as it
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N = int(input())
P = inpl()
Q = inpl()
ls = P.copy()
ls.sort()
cnt = 0
for l in it.permutations(ls):
    cnt += 1
    if P == l:
        a = cnt
    if Q == l:
        b = cnt
print(abs(a-b))
# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)
Problem p02886 (python)

Fixed submission:
import sys
import time
import math
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N = int(input())
d = inpl()
ans = 0
for i in range(N-1):
	for j in range(i+1, N):
		ans += d[i] * d[j]
print(ans)
	

# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
import sys
import time
import math
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N = int(input())
d = [int(input()) for _ in range(N)]
ans = 0
for i in range(N-1):
	for j in range(i+1, N):
		ans += d[i] * d[j]
print(ans)
	

# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)
Problem p03168 (python)

Fixed submission:
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**6)
import decimal
from decimal import Decimal
decimal.getcontext().prec = 10

from heapq import heappush, heappop, heapify
import math
from math import gcd
import itertools as it
import collections
from collections import deque 

def inp():
    return int(input())
def inpl():
    return list(map(int, input().split()))
def _debug(obj):
    print(obj, file=sys.stderr)

# ---------------------------------------

N = inp()
p = [0] + list(map(float, input().split()))
dp = [[0] * (N + 1) for i in range(N + 1)]
dp[0][0] = 1

for i in range(1, N+1):
    for j in range(0, i+1):
        if j > 0:
            dp[i][j] = dp[i-1][j] * (1 - p[i]) + dp[i-1][j-1] * p[i]
        else:
            dp[i][j] = dp[i-1][j] * (1 - p[i])
ans = 0
for j in range(N//2 + 1, N + 1):
    ans += dp[N][j]
print(ans)

Buggy submission (verdict: Runtime Error):
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**6)
from decimal import Decimal
decimal.getcontext().prec = 10

from heapq import heappush, heappop, heapify
import math
from math import gcd
import itertools as it
import collections
from collections import deque 

def inp():
    return int(input())
def inpl():
    return list(map(int, input().split()))
def _debug(obj):
    print(obj, file=sys.stderr)

# ---------------------------------------

N = inp()
p = [0] + list(map(Decimal, input().split()))
dp = [[0] * (N + 1) for i in range(N + 1)]
dp[0][0] = 1

for i in range(1, N+1):
    for j in range(0, i+1):
        if j > 0:
            dp[i][j] = dp[i-1][j] * (1 - p[i]) + dp[i-1][j-1] * p[i]
        else:
            dp[i][j] = dp[i-1][j] * (1 - p[i])
_debug(dp)
ans = 0
for j in range(N//2 + 1, N + 1):
    ans += dp[N][j]
print(ans)
Problem p03243 (python)

Fixed submission:
import sys
import time
import math
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N = int(input())
for i in range(N, 1000):
	if i//100==(i//10)%10:
		if i//100==i%10:
			print(i)
			sys.exit()

# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)

Buggy submission (verdict: Runtime Error):
import sys
import time
import math
def inpl():
    return list(map(int, input().split()))
st = time.perf_counter()
# ------------------------------

N = int(input())
for i in range(N, 1000):
	if N//100==N//10 ans N//10==N%10:
		print(N)
		sys.exit()

# ------------------------------
ed = time.perf_counter()
print('time:', ed-st, file=sys.stderr)
Problem p04012 (python)

Fixed submission:
import collections
w = list(input())

cnt = collections.Counter(w)
ans = "Yes"
for v in cnt.values():
    if v%2!=0:
        ans = "No"
        break
        
print(ans)

Buggy submission (verdict: Runtime Error):

def inp():
    return int(input())
def inpl():
    return list(map(int, input().split()))
def dbg(o):
    print(o, file=sys.stderr)

# ---------------------------------------

def main():
    s = input()
    dc = {}
    for st in s:
        if not st in dc:
            dc[st] = 1
        else:
            dc[st] += 1
    dbg(dc)
    for k, v in dc.items():
        if v % 2 == 1:
            print("No")
            exit()
    print("Yes")

main()