Harryxun/stf_run huggingface dataset:
# coding: utf-8
# Your code here!

d= int(input())

C = list(map(int,input().split()))
CB = [0 for i in range(len(C))]

c = sum(C)

total = 0

#print(c,C,CB)
L = []

for i in range(d):
    L.append(list(map(int,input().split())))

#print(L)

T = []

for i in range(d):
    T.append(int(input()))

#print(T)

def cnt(CB,t):
    for i in range(len(CB)):
        if i != t-1:
            CB[i] += 1
        else:
            CB[i] = 0
    
    return CB

def sumA(C,CB):
    a = 0
    for i in range(len(CB)):
        a += CB[i]*C[i]
    return a

for i in range(len(T)):
    CB = cnt(CB,T[i])
    total += L[i][T[i]-1] - sumA(C,CB)
    print(total)





### FIXED CODE ###

# coding: utf-8
# Your code here!
import numpy as np
d= int(input())

C = list(map(int,input().split()))
CB = [0 for i in range(len(C))]

c = sum(C)

total = 0

#print(c,C,CB)
L = []

for i in range(d):
    L.append(list(map(int,input().split())))

#print(L)


#print(T)

def cnt(CB,t):
    for i in range(len(CB)):
        if i != t:
            CB[i] += 1
        else:
            CB[i] = 0
    
    return CB

def sumA(C,CB):
    a = 0
    for i in range(len(CB)):
        a += CB[i]*C[i]
    return a

for i in range(d):
    ind = np.argmax(L[i])
    CB = cnt(CB,ind)
    total += L[i][ind] - sumA(C,CB)
    print(ind+1)
S,T=map(chr, input(),split())
A,B map(int, input(),split())
U = chr(input())
if S==U:
  A-=1
elif T==U:
  B-=1
print(A,B)

### FIXED CODE ###

S, T = input().split()
A, B= map(int, input().split())
U = input()
if S == U:
    print(A - 1, B)
else:
    print(A, B - 1)
a, b, c = map(int, input().split())
d = max(a, b)
l = []
for i in range(1,d+1):
  if a % i == 0 and b % i == 0:
    l.append(i)
rint(l[len(l)-c])

### FIXED CODE ###

a, b, c = map(int, input().split())
d = max(a, b)
l = []
for i in range(1,d+1):
  if a % i == 0 and b % i == 0:
    l.append(i)
print(l[len(l)-c])
x,y = list(map(int, input().split()))
count=0
for i in range(x):
	for j in range(x):
      for k in range(x):
        a=i+j+K
        if y==a:
          count+=1
print(count)

### FIXED CODE ###

x,y = list(map(int, input().split()))
count=0
for i in range(x+1):
    for j in range(x+1):
        k=y-i-j
        if k<=x and 0<=k:
          count+=1
print(count)
import numpy as np


l, r = map(int, input().split())
if l <= 2019 <= r:
    print(0)
    exit()
elif r*(r-1) <= 2019:
    print(l*(l+1))
    exit()

lr = np.arange(l,r+1)
lr = np.reshape(lr, (1,len(lr)))
lr_t = lr.T
mod = (lr*lr_t)%2019
mod = np.triu(mod, k=1)
mod = mod[np.triu_indices(len(mod),k=1)]
print(mod.min())


### FIXED CODE ###

l, r = map(int, input().split())
if l <= 2019 <= r:
    print(0)
    exit()
elif r*(r-1) <= 2019:
    print(l*(l+1))
    exit()

a = 2019
for i in range(l, r):
    for j in range(i+1, r+1):
        a = min(a, i*j%2019)
        if a == 0:
            print(0)
            exit()

print(a)
a=int(input())
b=int(input())
c=int(input())

print(a*b/2)

### FIXED CODE ###

a,b,c=map(int,input().split())
print(int((a*b)/2))
n = int(input())
boss_list = list(map(int, input().split(" ")))

boss_list = sorted(boss_list, reverse=True)


for i in range(n, 0, -1):
    boss_num = 0
    boss_num = boss_list.index(i-1)
    # boss_list = boss_list[boss_num:]
    del boss_list[:boss_num]

    if i == 0:
        boss_num -= 1

    print(boss_num)

### FIXED CODE ###

n = int(input())
boss_list = list(map(int, input().split(" ")))

boss_count_list = [0] * n


for val in boss_list:
  boss_count_list[val - 1] += 1

for val in boss_count_list:
  print(val)
if input()='SUN':
	print(7)
elif input()='MON':
  print(6)
elif input()='TUE':
  print(5)
elif input()='WED':
  print(4)
elif input()='THU':
  print(3)
elif input()='FRI':
  print(2)
elif input()='SAT':
  print(1)
end


### FIXED CODE ###

s=input()
if s=='MON':
  print(6)
elif s=='TUE':
  print(5)
elif s=='WED':
  print(4)
elif s=='THU':
  print(3)
elif s=='FRI':
  print(2)
elif s=='SAT':
  print(1)
else:
  print(7)
n=int(input())%1000
print(n is 0 0 else 1000-n)


### FIXED CODE ###

n=int(input())%1000
print(0 if n==0 else 1000-n)
i = int(input())
lst = []
while i > 0:
    lst.append(i%10)
    i //= 10 
lst.reverse()
a=lst[0]
b=lst[1]
c=lst[2]
d=lst[3]
sa=str(a)
sb=str(b)
sc=str(c)
sd=str(d)

if(a+b+c+d==7):
    print(sa+"+"+sb+"+"+sc+"+"+sd+"=7")
elif (a+b+c-d==7):
    print(sa+"+"+sb+"+"+sc+"-"+sd+"=7")
elif (a+b-c+d==7):
    print(sa+"+"+sb+"-"+sc+"+"+sd+"=7")
elif(a-b+c+d==7):
    print(sa+"-"+sb+"+"+sc+"+"+sd+"=7")
elif(a-b-c+d==7):
    print(sa+"-"+sb+"-"+sc+"+"+sd+"=7")
elif(a-b+c-d==7):
    print(sa+"-"+sb+"+"+sc+"-"+sd+"=7")
elif(a+b-c-d==7):
    print(sa+"+"+sb+"-"+sc+"-"+sd+"=7")
elif(a-b-c-d==7):
    print(sa+"-"+sb+"-"+sc+"-"+sd+"=7")
else:
  print('none')

### FIXED CODE ###

i = input()

a=int(i[0])
b=int(i[1])
c=int(i[2])
d=int(i[3])
sa=i[0]
sb=i[1]
sc=i[2]
sd=i[3]

if(a+b+c+d==7):
    print(sa+"+"+sb+"+"+sc+"+"+sd+"=7")
elif (a+b+c-d==7):
    print(sa+"+"+sb+"+"+sc+"-"+sd+"=7")
elif (a+b-c+d==7):
    print(sa+"+"+sb+"-"+sc+"+"+sd+"=7")
elif(a-b+c+d==7):
    print(sa+"-"+sb+"+"+sc+"+"+sd+"=7")
elif(a-b-c+d==7):
    print(sa+"-"+sb+"-"+sc+"+"+sd+"=7")
elif(a-b+c-d==7):
    print(sa+"-"+sb+"+"+sc+"-"+sd+"=7")
elif(a+b-c-d==7):
    print(sa+"+"+sb+"-"+sc+"-"+sd+"=7")
elif(a-b-c-d==7):
    print(sa+"-"+sb+"-"+sc+"-"+sd+"=7")
def judge(s):
    si = 0
    for t in T:
        if t == s[si]:
            si += 1
            if si == len(s): return True
    return False

S,T = input(),input()
N = len(S)
print('Yes' if judge(S[::2]) or judge(S[1::2]) else 'No')

### FIXED CODE ###

def judge(s):
    if len(s) == 0: return True
    si = 0
    for t in T:
        if t == s[si]:
            si += 1
            if si == len(s): return True
    return False

S,T = input(),input()
N = len(S)
print('Yes' if judge(S[::2]) or judge(S[1::2]) else 'No')
N, M = [int(i) for i in input().split()]
A = [int(i) for i in input().split()]
total_votes = sum(A)
minimum_votes = int(total_votes / (4 * M)))
eligible_products = 0

for vote in A:
    if vote >= minimum_votes:
        eligible_products += 1

if eligible_products >= M:
    print("Yes")
else:
    print("No")


### FIXED CODE ###

N, M = [int(i) for i in input().split()]
A = [int(i) for i in input().split()]
minimum_votes = sum(A) * (1 / (4 * M))

eligible_products = [a for a in A if a >= minimum_votes]

if len(eligible_products) >= M:
    print("Yes")
else:
    print("No")
N=int(input())
S=input
c=0
for i in range(0,N-2):
  if S[i;i+2]="ABC":
    c+=1
return c    

### FIXED CODE ###

N=int(input())
S=input()
c=0
for i in range(N-2):
  if S[i:i+3]=="ABC":
    c+=1
print(c)
def bbq():
    n = int(input())
    a = input()
    tmp = a.split()
    l = [int(x) for x in tmp]
    l.sort()
    n = 0
    i = 0
    while(i<n:
        n += l[i]
        i += 2
    print (n)

if __name__ == "__main__":
    bbq()

### FIXED CODE ###

def bbq():
    n = int(input())
    a = input()
    tmp = a.split()
    l = [int(x) for x in tmp]
    l.sort()
    n = 0
    i = 0
    while(i<len(l)):
        n += l[i]
        i += 2
    print (n)

if __name__ == "__main__":
    bbq()
from typing import List


class Solution:
    def solve(self, a: int, b: int) -> int:

        if 1 <= a <= 9 and 1 <= b <= 9:
            return a*b
        else:
            return -1


if __name__ == '__main__':

    # standard input
    a, b = map(int, input().split())

    # solve
    solution = Solution()
    print(solution.solve(a, b))


### FIXED CODE ###

class Solution:
    def solve(self, a: int, b: int) -> int:

        if 1 <= a <= 9 and 1 <= b <= 9:
            return a*b
        else:
            return -1


if __name__ == '__main__':

    # standard input
    a, b = map(int, input().split())

    # solve
    solution = Solution()
    print(solution.solve(a, b))
def rle(s):#計算量N
    c = 0
    tmp, count, ans = s[0], 1, []
    for i in range(1,len(s)):
        if tmp == s[i]:
            count += 1
        else:
            ans.append((-1)*count)
            c += count-1
            count = 1
            tmp = s[i]
    if count > 1:
        ans.append(count*(-1))
        c += count-1
    return ans,c #最大2N文字
N,K = map(int,input().split())
S = input()
ans,c = rle(S)
import heapq
heapq.heapify(ans)
for i in range(K):
    a = heapq.heappop(ans)
    c += 2
if c >= N:
    c = N-1
print(c)

### FIXED CODE ###

import sys
input=sys.stdin.readline
#from collections import defaultdict
#d = defaultdict(int)
#import fractions
#import math
#import collections
#from collections import deque
#from bisect import bisect_left
#from bisect import insort_left
#N = int(input())
#A = list(map(int,input().split()))
#S = list(input())
#S.remove("\n")
#N,M = map(int,input().split())
#S,T = map(str,input().split())
#A = [int(input()) for _ in range(N)]
#S = [input() for _ in range(N)]
#A = [list(map(int,input().split())) for _ in range(N)]
#import itertools
#import heapq
#import numpy as np
def rle(s):#計算量N
    c = 0
    tmp, count, ans = s[0], 1, []
    for i in range(1,len(s)):
        if tmp == s[i]:
            count += 1
        else:
            ans.append((-1)*count)
            c += count-1
            count = 1
            tmp = s[i]
    if count > 1:
        ans.append(count*(-1))
        c += count-1
    return ans,c #最大2N文字
N,K = map(int,input().split())
S = input()
ans,c = rle(S)
n = len(ans)
import heapq
heapq.heapify(ans)
MIN = min(n,K)
for i in range(MIN):

    a = heapq.heappop(ans)
    c += 2
if c >= N:
    c = N-1
print(c)
N,M=map(int,input().split())

pair=[list(map(lambda x:int(x)-1,input().split())) for _ in range(M)]
graph=[[0]*N for _ in range(N)] #隣接行列の初期化


for p in pair:
	graph[p[0]][p[1]]= graph[p[1]][p[0]]=1
	
def DFS(v):
	if visited[v]:
		return 
	visited[v]=True
	for j in [j for j,v2 in enumerate(graph[v]) if v2==1]:
		DFS(j)
		
res = 0

for i in range(M):
	visited=[False for _ in range(N)] #訪問済みリストの初期化
	x,y=pair[i]
	graph[x][y]=graph[y][x]=0 #辺を取り除く
	DFS(0 if i>0 else 1)
	
	if not all(visited): #全ての頂点が訪問済みでなかった場合
		res+=1
	
	graph[x][y]=graph[y][x]=1

print(res)

### FIXED CODE ###

A,B,C=list(input().split())

if A==B:
	print(C)
elif B==C:
	print(A)
else:
	print(B)
n,k = map(int,input().split())
if abs(k-n)>n:
  print(n)
elif k==1:
  print(0)
else:
  print(n%abs(k-n))

### FIXED CODE ###

n,k = map(int,input().split())
if abs(k-n)>n:
  print(n)
elif k==1 or k==n or n==0:
  print(0)
elif n<k:
  print(k%n)
else:
  n = k+ n%k
  n1 = n%k
  while n1<n:
    n=n1
    n1 = abs(k-n1)
  print(n)
s = str(input())
if s[3]==s[4] and s[5]==s[6]:
  print("Yes")
else:
  print("No")

### FIXED CODE ###

s = str(input())
if (s[2]==s[3]) and (s[4]==s[5]):
    print("Yes")
else:
    print("No")
n=int(input())
a=list(map(int,input().split()))
ct=[0]*n
cmb=[0]*n
s_cmb=0
for i in range(0,n):
  ct[a[i]]+=1
for i in range(0,n):
  cmb[i]=ct[i]*(ct[i]-1)//2
  s_cmb+=cmb[i]
for i in range(0,n):
  print(s_cmb-cmb[a[i]]+(ct[a[i]]-1)*(ct[a[i]]-2)//2)

### FIXED CODE ###

n=int(input())
a=list(map(int,input().split()))
ct=[0]*n
cmb=[0]*n
s_cmb=0
for i in range(0,n):
  a[i]-=1
  ct[a[i]]+=1
for i in range(0,n):
  cmb[i]=ct[i]*(ct[i]-1)//2
  s_cmb+=cmb[i]
for i in range(0,n):
  print(s_cmb-cmb[a[i]]+(ct[a[i]]-1)*(ct[a[i]]-2)//2)
key = input()
s = []
for i in key:
  if i == '0' or if i == '1':
    s.append(i)
  else:
    len(s) > 0:
      s.pop(-1)
print(s)


### FIXED CODE ###

key = input()
s = []
for i in key:
  if i == '0' or i == '1':
    s.append(i)
  else:
    if len(s) > 0:
      s.pop(-1)
print(''.join(s))
pow(x,x)

### FIXED CODE ###

x = int(input())
print(x**3)
def main():
    num = input()
    num_list = list(map(int, input().split(" ")))
    # result = sum([sum([num_list[i]^num_list[j] for j in range(i)]) for i in range(int(num))])
    result = 0
    for i in range(int(num)):
        for j in range(i):
            result += num_list[i]^num_list[j]
    print(result%(10**9+7))    

if __name__ == "__main__":
    main()

### FIXED CODE ###

import sys

def main():
    input_list = input().split(" ")
    a1, a2, a3 = int(input_list[0]), int(input_list[1]), int(input_list[2])
    if a1 + a2 + a3 >= 22:
        print('bust')
    else:
        print('win')

if __name__ == "__main__":
    main()
A=input()
B=input()
C=input()
D=input()
a=int(A)
b=int(B)
c=int(C)
d=int(D)

if a < c :
    max=c
else :
    max=a
    
if b > d :
    min=d
else :
    min=b
if ( min - max ) > 0 :
    print( min - max )
    print('\n')
else :
    print('0\n')
quit()


### FIXED CODE ###



a,b,c,d=[int(i) for i in input().strip().split(' ')]

'''
入力は他の人のを見た
'''

max=0
min=0

if a < c :
    max=c
else :
    max=a
    
if b > d :
    min=d
else :
    min=b
if ( min - max ) > 0 :
    print( min - max )
else :
    print(0)
def main():
    N, M = map(int, input().split())
    a = [0] * (1 + 10 ** 5)
    for _ in range(M):
        a[int(input())] = 1
    dp = [0] * (N + 1)
    dp[0] = 1
    if not a[1]:
        dp[1] = 1

    for i in range(2, N + 1):
        if not a[i]:
            dp[i] += dp[i-1] + d[i-2]
            dp[i] %= 1000000007

    print(dp[N])

main()


### FIXED CODE ###

N, M = map(int, input().split())
a = set(int(input()) for _ in range(M))
dp = [0] * (N + 1)
dp[0] = 1
if 1 not in a:
    dp[1] = 1

for i in range(2, N + 1):
    for k in [-2, -1]:
        if i + k not in a:
            dp[i] += dp[i+k]

print(dp[N] % 1000000007)
d = map(int, input().split())

sorted(d.items(), key=lambda x: x[1])

### FIXED CODE ###

ary=list(map(int, input().split()))
ary.sort()
print("{} {} {}".format(ary[0], ary[1], ary[2]))
r = int(input().split())

print(int(r*r))

### FIXED CODE ###

r = int(input())
 
print(r*r)
import numpy as np
A, B, M = map(int, input().split())
a = np.array(list(map(int, input().split())))
b = np.array(list(map(int, input().split())))
m = np.zeros((A, B), dtype="int64")

for i in range(M):
    x, y, c = map(int, input().split())
    if m[x-1][y-1] < c:
        m[x-1][y-1] = c

ans = 9999999999
for i in range(A):
    for j in range(B):
        price = a[i] + b[j] - m[i][j]
        if price < ans:
            ans = price
print(ans)

### FIXED CODE ###

A, B, M = map(int, input().split())
a = list(map(int, input().split()))
b = list(map(int, input().split()))
ans = min(a) + min(b)
for i in range(M):
    x, y, c = map(int, input().split())
    price = a[x-1] + b[y-1] - c
    if ans > price:
        ans = price
print(ans)
n, r = map(int, input().split())
if n < 10:
  return r
else:
  return 100 * (10 - n)


### FIXED CODE ###

def main():
  n, r = map(int,input().split())
  if n > 9:
    print(r)
  else:
    print(r + 100 * (10 - n))

main()
"""負辺ありの有向グラフの最短経路問題、ベルマンフォード法"""

n,m,p = map(int, input().split())

INF = 1001001001

to = [[] for _ in range(2505)]
rto = [[] for _ in range(2505)]
reachableFrom1 = [False for _ in range(2505)]
reachableToN = [False for _ in range(2505)]
ok = [False for _ in range(2505)]

def dfs(v):
    """1から到達できる頂点の列挙"""
    if reachableFrom1[v]: return
    reachableFrom1[v] = True
    for u in to[v]:
        dfs(u)

def rdfs(v):
    """Nに到達できる頂点の列挙"""
    if reachableToN[v]: return
    reachableToN[v] = True
    for u in rto[v]:
        rdfs(u)

edges = []
for i in range(m):
    a,b,c = map(int, input().split())
    a -= 1; b -= 1
    c -= p
    c = -c
    edges.append((a,b,c))
    to[a].append(b) # 到達可能性を判定するための変数
    rto[b].append(a) # nに辿り着けるかを判定するための変数
    
dfs(0)
rdfs(n-1)

for i in range(n):
    ok[i] = reachableFrom1[i] & reachableToN[i] # okになっている頂点だけを考える

# ベルマンフォード
def main():
    global edges, ok
    d = [INF for _ in range(n)]
    d[0] = 0
    upd = True
    step = 0 # 負閉路検出用。更新回数がnステップを超えたら負閉路あり
    while upd:
        upd = False
        for i in range(m):
            a,b,c = edges[i]
            if not ok[a]: continue
            if not ok[b]: continue
            newD = d[a]+c
            if newD < d[b]:
                upd = True
                d[b] = newD
        step += 1
        if step > n:
            print(-1)
            return
    ans = -d[n-1]
    ans = max(ans,0)
    print(ans)
    return
    
main()

### FIXED CODE ###

"""負辺ありの有向グラフの最短経路問題、ベルマンフォード法"""
import sys
sys.setrecursionlimit(10**6)

n,m,p = map(int, input().split())

INF = 1001001001

to = [[] for _ in range(2505)]
rto = [[] for _ in range(2505)]
reachableFrom1 = [False for _ in range(2505)]
reachableToN = [False for _ in range(2505)]
ok = [False for _ in range(2505)]

def dfs(v):
    """1から到達できる頂点の列挙"""
    if reachableFrom1[v]: return
    reachableFrom1[v] = True
    for u in to[v]:
        dfs(u)

def rdfs(v):
    """Nに到達できる頂点の列挙"""
    if reachableToN[v]: return
    reachableToN[v] = True
    for u in rto[v]:
        rdfs(u)

edges = []
for i in range(m):
    a,b,c = map(int, input().split())
    a -= 1; b -= 1
    c -= p
    c = -c
    edges.append((a,b,c))
    to[a].append(b) # 到達可能性を判定するための変数
    rto[b].append(a) # nに辿り着けるかを判定するための変数
    
dfs(0)
rdfs(n-1)
for i in range(n):
    ok[i] = reachableFrom1[i] & reachableToN[i] # okになっている頂点だけを考える
# ベルマンフォード
def main():
    global edges, ok
    d = [INF for _ in range(n)]
    d[0] = 0
    upd = True
    step = 0 # 負閉路検出用。更新回数がnステップを超えたら負閉路あり
    while upd:
        upd = False
        for i in range(m):
            a,b,c = edges[i]
            if not ok[a]: continue
            if not ok[b]: continue
            newD = d[a]+c
            if newD < d[b]:
                upd = True
                d[b] = newD
        step += 1
        if step > n:
            print(-1)
            return
    ans = -d[n-1]
    ans = max(ans,0)
    print(ans)
    return
    
main()
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
hantei = 0

x = [a,b,c,d,e]

for i in x:
 for j in x:
    if i - j > k:
        hantei.append(1)


if hantei == 0:
    print("Yay!")
else:
    print(":(")


### FIXED CODE ###

a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())

x = [a,b,c,d,e]

x.sort()
if x[4] - x[0] <= k:
    print("Yay!")
else:
    print(":(")
import math
N=input()
x=[]
y=[]
M=0
for i in N:
    F=input()
    v,s=F.split(' ')
    x.append(v)
    y.append(s)
def dis(x,y,x2,y2):
    return math.sqrt((x-x2)**2+(y-y2)**2)
for i in N:
    for j in N:
        M=M+dis(x[i],y[i],x[j],y[j])
print(M/math.factorial(N))

### FIXED CODE ###

import math
N=int(input())
x=[]
y=[]
M=0
for i in range(0,N):
    F=input()
    [v,s]=list(map(int,F.split(' ')))
    x.append(v)
    y.append(s)
def dis(x,y,x2,y2):
    return math.sqrt((x-x2)**2+(y-y2)**2)
for i in range(0,N):
    for j in range(0,N):
        M=M+dis(x[i],y[i],x[j],y[j])
print(M/N)
import math
A, B = map(int, input().split())
g = gcd(A, B)
pn = [2]
for L in range(3, g):
    chk=True
    for L2 in pn:
        if L%L2==0:chk=False
    if chk==True and gcd(g,L)!=1:pn.append(L)
print(len(pn)+1)

### FIXED CODE ###

def gcd(a, b):
    return gcd(b, a%b) if b!=0 else a

def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)
    return divisors

def isprime(n):
    sup = int(n**0.5)
    for i in range(2, sup+1):
        if n%i==0:
            return False
    return True

A, B = map(int, input().split())
g = gcd(A, B)
divs = make_divisors(g)
ans = 0
for d in divs:
    ans += 1 if isprime(d) else 0
print(ans)
x = input()
print(x*x*x/n)

### FIXED CODE ###

x = input()
print(int(x) **3)
class Node:
    parent = NIL
    left = NIL
    right = NIL
    label = ""


def show_info(u):
    global T, D
    if T[i].parent == NIL:
        T[u].label = "root"
    elif T[i].left == NIL:
        T[u].label = "leaf"
    else:
        T[u].label = "internal node"
    print('node {0}: parent = {1}, depth = {2}, {3}, {4}'.format(u, T[u].parent, D[u], T[u].label, getChildren(u)))


def getChildren(u):
    global T
    c = T[u].left
    R =[]
    while c != NIL:
        R.append(c)
        c = T[c].right
    return R


def setDepth(u,p):
    global T, D
    D[u] = p
    if T[u].right != NIL:
        setDepth(T[u].right, p)
    if T[u].left != NIL:
        setDepth(T[u].left, p + 1)


if __name__ == "__main__":
    n = int(input())
    T = [None] * n
    D = [None] * n
    for i in range(n):
        T[i] = Node()
    for i in range(n):
        tmp = list(map(int, input().split()))
        id = tmp.pop(0)
        k = tmp.pop(0)
        C = tmp
        if k != 0:
            T[id].left = C[0]
            for j in range(len(C)):
                T[C[j]].parent = id
            for j in range(len(C) - 1):
                T[C[j]].right = C[j + 1]
    # ??±????¨????
    setDepth(0, 0)
    for i in range(n):
        show_info(i)

### FIXED CODE ###

NIL = -1


class Node:
    parent = NIL
    left = NIL
    right = NIL


def getDepth(u):
    d = 0
    while T[u].parent != NIL:
        u = T[u].parent
        d += 1
    return d


def getChildren(u):
    c = T[u].left
    result = []
    while c != NIL:
        result.append(c)
        c = T[c].right
    return result


n = int(input())
T = [0] * n
for i in range(n):
    T[i] = Node()

for i in range(n):
    tmp = list(map(int, input().split()))
    id = tmp.pop(0)
    k = tmp.pop(0)
    c = tmp
    if k != 0:
        for j in range(len(c)):
            T[c[j]].parent = id
        T[id].left = c[0]
        for j in range(len(c) - 1):
            T[c[j]].right = c[j + 1]

for i in range(n):
    d = getDepth(i)
    c = getChildren(i)
    if d == 0:
        t = 'root'
    elif c == []:
        t = 'leaf'
    else:
        t = 'internal node'
    print('node ', i, ': ', 'parent = ', T[i].parent, ', depth = ', d, ', ', t, ', ', c, sep='')
A, B = map(long, raw_input().split())
ans = 0
msb = B >> (B.bit_length()-1) << (B.bit_length() - 1)
if msb + A > B:
    pos = A
else:
    pos = msb + A
for i in range(B, A-1, -1):
    ans ^= i
print(ans)


### FIXED CODE ###

A, B = map(int, input().split())
ans = 0
cnt = 0
def f(arg):
    ans = 0
    if arg < 0:
        return 0
    for pos in range(1, 41):
        # ループする数
        loop = 1 << pos
        # cnt = sum([int((n & v) / v) for n in range(arg+1)])
        cnt = int((arg + 1) / loop) * (loop >> 1)
        cnt += max(0, (arg + 1) % (loop) - (loop >> 1))
        ans += cnt%2 * (loop>>1)
        # print(arg, pos, loop, cnt, ans)
        if loop > arg:
            break
    return ans
print(f(A-1)^f(B))
a = list(map(int, input().split()))
r = a[0]
g = a[1]
b = a[2]
n = a[3]
c = 0

for i in range(n+1):
    for j in range(n+1):
        k = (n - (r*i + g*j))//b
        if k >= 0:
            if n == r*i + g*j + b*k:
                c += 1
print(c)

### FIXED CODE ###

n = list(map(int, input().split()))
a =[]
c = 1
b = []

for i in range(1, n[0]+1):
    b.append(i)

for j in range(1, n[1]+1):
    a.append(j)

for k in range(b[-1]):
    if b[-1] == a[-1]:
        print(c)
        break
    else:
        a[-1] += 1
        c += 1
loop = int(raw_input())
have_card = []
for i in range(i):
    have_card.append(raw_input())
for i in range(4):
    if i == 0:
        g = 'S'
    elif i == 1:
        g = 'H'
    elif i == 2:
        g = 'C'
    elif i == 3:
        g = 'D'
    for j in range(1, 14):
        card = g + ' ' + str(j)
        if not card in have_card:
            print card

### FIXED CODE ###

loop = int(raw_input())
have_card = []
for i in range(loop):
    have_card.append(raw_input())
for i in range(4):
    if i == 0:
        g = 'S'
    elif i == 1:
        g = 'H'
    elif i == 2:
        g = 'C'
    elif i == 3:
        g = 'D'
    for j in range(1, 14):
        card = g + ' ' + str(j)
        if not card in have_card:
            print card
import sys, os

f = lambda:list(map(int,input().split()))
if 'local' in os.environ :
    sys.stdin = open('./input.txt', 'r')

def solve():
    a,b = f()
    for i in range(1,4):
        if a*b*c%2 == 1:
            print("Yes")
            return
    
    print('No')
    

solve()


### FIXED CODE ###

import sys, os

f = lambda:list(map(int,input().split()))
if 'local' in os.environ :
    sys.stdin = open('./input.txt', 'r')

def solve():
    a,b = f()
    for i in range(1,4):
        if a*b*i%2 == 1:
            print("Yes")
            return
    
    print('No')
    

solve()