Harryxun/stf_run huggingface dataset:
# D - Coloring Edges on Tree

n = int(input())
A = []
B = []

# 2次元配列で辺（頂点,遷移先の頂点）を管理する
D = [[] for _ in range(n)]

for _ in range(n-1):
    a, b = map(int, input().split())
    a -= 1
    b -= 1
    D[a].append(b)
    D[b].append(a)
    A.append(a)
    B.append(b)

print(max([len(d) for d in D]))

C = {}

def dfs(node, par, col):
    cid = 1
    for chi in D[node]:
        if chi==par:
            continue
        else:
            if cid==col:
                cid += 1
            C[(node, chi)] = cid
            dfs(chi, node, cid)
            cid += 1

dfs(0,0,0)

for a, b in zip(A, B):
    print(C[(a,b)])

### FIXED CODE ###

# D - Coloring Edges on Tree
import sys
sys.setrecursionlimit(10**6)

n = int(input())
A = []
B = []

# 2次元配列で辺（頂点,遷移先の頂点）を管理する
D = [[] for _ in range(n)]

for _ in range(n-1):
    a, b = map(int, input().split())
    a -= 1
    b -= 1
    D[a].append(b)
    D[b].append(a)
    A.append(a)
    B.append(b)

print(max([len(d) for d in D]))

C = {}

def dfs(node, par, col):
    cid = 1
    for chi in D[node]:
        if chi==par:
            continue
        else:
            if cid==col:
                cid += 1
            C[(node, chi)] = cid
            C[(chi, node)] = cid
            dfs(chi, node, cid)
            cid += 1

dfs(0,0,0)

for a, b in zip(A, B):
    print(C[(a,b)])
x = list(int(input))
for i in range(len(x)):
    for a in x:
        if x == 0:
            break
print("Case {0}: {1}".format(i,a))

### FIXED CODE ###

import sys
a = 1

for i in sys.stdin:
        x = i.strip()
        if x == "0":
                break;
        print("Case {0}: {1}".format(a,x))
        a += 1
a,b,n = map(int,input().split())
ans = 0
for k in range(1,min(b,n+1)):
    ans = max(int(a*k/b) - a*int(k/b),ans)
    if ans == a:
        print(ans)
        break
if ans == a:
    ans = ans
else:
    for k in range(1,n//(b-1)+1):
        ans = max(int(a*(k*b-1)/b) - a*int((k*b-1)/b),ans)
        if ans == a:
            print(ans)
            break
if ans != a:
    print(ans)

### FIXED CODE ###

a,b,n = map(int,input().split())
ans = 0
ans = max(int(a*n/b) - a*int(n/b),ans)
if b == 1:
    print(0)
else:
    for k in range(1,n//(b-1)+1):
        ans = max(int(a*(k*b-1)/b) - a*int((k*b-1)/b),ans)
        if ans == a:
            print(ans)
            break
    if ans != a:
        print(ans)
def main():
    import numpy as np
    
    N = int(input())
    
    s = np.linspace(1, N-1, N-1)
    res = np.sum(s)

    print(int(res))
    
main()

### FIXED CODE ###

def main():
    N = int(input())
    res = N*(N-1)//2
    print(res)
    
main()
N , M =map(int,input().split())
A_n =list(map(int,input().split()))

B_n=sorted(A_n)
i =0
count =len(B_n)
while B_n[i] < sum(B_n)/(4*M):
    i +=1
    count -=1
if count >= M:
    print('Yes')
else:
    print('No')

### FIXED CODE ###

N , M =map(int,input().split())
A_n =list(map(int,input().split()))

B_n=sorted(A_n,reverse=True)

if B_n[M-1] >= sum(B_n)/(4*M) :
    print('Yes')
else:
    print('No')
import sys
sys.setrecursionlimit(10*50)
N, M = map(int, input().split())
A = [int(input()) for _ in range(M)]
MOD = 1000000007
def Fib(n, A, MOD, memo={}):
    if n in A:
        return 0
    elif n == 1:
        return 1
    elif n == 2:
        if 1 in A:
            return 1
        else:
            return 2
    elif n in memo:
        return memo[n]
    else:
        memo[n] = ( Fib(n-1, A, MOD, memo) + Fib(n-2, A, MOD, memo) ) % MOD
        return memo[n]

print(Fib(N, A, MOD))


### FIXED CODE ###

N, M = map(int, input().split())
A = set([int(input()) for _ in range(M)])
MOD = 1000000007
memo = [0]*(N+1)
memo[0] = 1
if 1 not in A:
    memo[1] = 1
for i in range(2, N+1):
    if i not in A:
        memo[i] = (memo[i-2] + memo[i-1])%MOD
print(memo[N])
import itertools
n, a, b, k = map(int, input().split())
count = 0
for i in range(n):
    if (n - (i * a)) % b == 0:
        count += (itertools.combinations(n, i) * itertools.combinations(n, (n-i*a)/b))
print(count/998244353)

### FIXED CODE ###

N,A,B,K = map(int,input().split())
sprime = 998244353 # approx 10**9
A,B = sorted((A,B))
if (A+B) * N < K:
	print(0)
	exit()
 
def egcd(a, b):
    if a == 0:
        return (b, 0, 1)
    else:
        g, y, x = egcd(b % a, a)
        return (g, x - (b // a) * y, y)
 
def modinv(a, m):
    g, x, y = egcd(a, m)
    if g != 1:
        raise Exception('modular inverse does not exist')
    else:
        return x % m
 
memo = [0] * (N+1)
memo[0] = memo[N] = 1
for i in range(1,N//2+1):
	v = memo[i-1] * (N-i+1) * modinv(i,sprime)
	v = v % sprime
	memo[i] = memo[N-i] = v
 
# max is A*N + B*N
sum = 0
for b in range(N+1):
  a = (K-b*B)//A
  if 0 <= a <= N and a*A+b*B == K:
    sum += memo[a]*memo[b]
    sum %= sprime
 
print(sum)
n = input()

if n[len(n - 1)] == 's':
    print(n + 'es')
else:
    print(n + 's')

### FIXED CODE ###

n = input()

if n[len(n) - 1] == 's':
    print(n + 'es')
else:
    print(n + 's')
def main():
    n =int( input())
    sn=[]
    for i in range(n):
        
        inWord = str(input())
        addFlag = True
        for s in sn:
            if s["word"] == inWord and len(sn) !=0:
                s["count"]+=1
                addFlag = False
                break
        if addFlag ==True:
            sn.append( {"word":inWord,"count":1})
        
    a= sorted(sn, reverse=True,key=lambda x:x['count'])
    most = a[0]["count"]

    mostWords=[]
    for elm in a:
        if elm["count"] == most:
            mostWords.append(elm["word"])
    mostWords.sort()

    for elm in mostWords:
        print(elm)
    return

main()



### FIXED CODE ###

A, B, C = map(int, input().split())

if A == B or B == C or C == A:
    if A == B and B == C:
        print("No")
    else:
        print("Yes")

else:
    print("No")
import sys
stdin = sys.stdin
sys.setrecursionlimit(10**9)
ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))
nn = lambda: list(stdin.readline().split())
ns = lambda: stdin.readline().rstrip()

n = ni()
a = na()

if n%2 == 0:
	print(['No','Yes'][all([e == a[0] for e in a[1:] and a[0] == 0])])
else:
	a = sorted(a)
	b = [a[0]]
	for i in range(1,n):
		b.append(a[0]^a[i])
	b = sorted(b)
	c = a[-1::-1]
	d = [c[0]]
	for i in range(1,n):
		d.append(c[0]^c[i])
	c = sorted(c)
	d = sorted(d)
	print(['No','Yes'][a==b and c==d])


### FIXED CODE ###

import sys
stdin = sys.stdin
sys.setrecursionlimit(10**6)
ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))
nn = lambda: list(stdin.readline().split())
ns = lambda: stdin.readline().rstrip()

n = ni()
a = sorted(na())
x = [[0]*n for _ in range(30)]
 
if n%3:
    if max(a):
        print("No")
    else:
        print("Yes")
else:
    m = n//3
    if a[0] == a[m-1] and a[m] == a[2*m-1] and a[2*m] == a[3*m-1] and a[0]^a[m] == a[2*m]:
        print("Yes")
    else:
        print("No")
import numpy as np

X, N= map(int,input().split())
P = list(map(int, input().split()))
P = list(set(P))

if N == 0:
    print(X)
else:
    A = [i for i in range(1,101)]

    for i in P:
        A.remove(i)

    a = (np.array(A) - X)**2
    j = np.argmin(a)
    if (A[j] - X)**2 >= X**2:
        print(0)
    else:
        print(A[j])

### FIXED CODE ###

import numpy as np

X, N= map(int,input().split())
P = list(map(int, input().split()))
P = list(set(P))

if N == 0:
    print(X)
else:
    A = [i for i in range(1,210)]

    for i in P:
        A.remove(i)

    a = (np.array(A) - X)**2
    j = np.argmin(a)
    if (A[j] - X)**2 >= X**2:
        print(0)
    else:
        print(A[j])
k, x = map(int, input().spilt())
if 500*k >= x:
	print("Yes")
else:
	print ("No")

### FIXED CODE ###

k, x = map(int, input().split())
if k*500 >= x:
	print ("Yes")
else:
	print ("No")
import numpy as np

n, k = map(int, input().split())
A = np.array(list(map(int, input().split())))

S = A.cumprod().tolist()
#print(S)
tmp = S[k-1]
for i in range(k-1):
    if tmp < S[k+i]/S[i]:
        print("Yes")
    else:
        print("No")
    #print(tmp, S[k+i]/S[i])

    tmp = S[k+i]/S[i]



### FIXED CODE ###

n, k = map(int, input().split())
A = list(map(int, input().split()))

for i in range(n-k):
    if A[i] < A[k+i]:
        print("Yes")
    else:
        print("No")
N = int(input().strip())

count = 0
while True:
    if (count + 1) ** 2 > N:
        print(count ** 2)
        break
    count += 1

### FIXED CODE ###

line1 = input().strip()
line2 = input().strip()

if line1[0] == line2[2] and line1[1] == line2[1] and line1[2] == line2[0]:
    print("YES")
else:
    print("NO")
import math
n = int(input())
T = []
ans = 1
for i in range(n):
    t = int(input())
    T.append(t)
    ans = ans * t // math.gcd(ans, t)
print(ans)

### FIXED CODE ###

import fractions
n = int(input())
T = []
ans = 1
for i in range(n):
    t = int(input())
    T.append(t)
    ans = ans * t // fractions.gcd(ans, t)
print(ans)
A,B,C,D = map(int,input().split())
def gcd(x,y):
  if x<y:
    l = y
    k = x
    x = y
    y = k
  z = x%y
  while z != 0:
    x = y
    y = z
    z = x%y
  return (k//y)*(l//y)*y

if A%C ==0:
  i = (A//C)-1
else:
  i = A//C

j = B//C

if A%D ==0:
  k = (A//D)-1
else:
  k = A//D

l = B//D

if A%(gcd(C,D)) ==0:
  m = (A//(gcd(C,D)))-1
else:
  m = A//gcd(C,D)
  
n = B//gcd(C,D)

#print(i,j,k,l,m,n)
#print(B-A+1,j-i,l-k,n-m)
print((B-A+1)-(j-i)-(l-k)+(n-m))

### FIXED CODE ###

A,B,C,D = map(int,input().split())
def gcd(x,y):
  if x<y:
    l = y
    k = x
    x = y
    y = k
  else:
    k = y
    l = x
  z = x%y
  while z != 0:
    x = y
    y = z
    z = x%y
  return (k//y)*(l//y)*y

if A%C ==0:
  i = (A//C)-1
else:
  i = A//C

j = B//C

if A%D ==0:
  k = (A//D)-1
else:
  k = A//D

l = B//D

if A%(gcd(C,D)) ==0:
  m = (A//(gcd(C,D)))-1
else:
  m = A//gcd(C,D)
  
n = B//gcd(C,D)

#print(i,j,k,l,m,n)
#print(B-A+1,j-i,l-k,n-m)
print((B-A+1)-(j-i)-(l-k)+(n-m))
n=int(input())
'''
import sys
sys.setrecursionlimit(1000000)
def kaijo(n):
    if n==0:
        return(1)
    else:
        n=n%(10**9+7)
        return(n*kaijo(n-1))
print(kaijo(n)%(10**9+7))
'''
ans=1
for i in range(1,n+1):
    ans*=i%(10**)+7
print(ans%(10**9+7))

### FIXED CODE ###

n=int(input())
'''
import sys
sys.setrecursionlimit(1000000)
def kaijo(n):
    if n==0:
        return(1)
    else:
        n=n%(10**9+7)
        return(n*kaijo(n-1))
print(kaijo(n)%(10**9+7))
'''
ans=1
for i in range(1,n+1):
    ans=i*(ans%(10**9+7))
print(ans%(10**9+7))
import sys

def jump(k: int, h, res):
    if ( k == 0 ):
        return 0

    if ( res[k] == -1 ):
        res[k] = jump(k - 1, h, res) + abs(h[k] - h[k - 1])
        if k >= 2:
            res[k] = min(res[k], jump(k - 2, h, res) + abs(h[k] - h[k - 2]))

    return res[k]
   

def main():
    #lines = []
    #for line in sys.stdin:
    #    lines.append([int(i) for i in line.strip().split(' ')])

    #n = int(lines[0][0])
    #h = lines[1]
    n = int(input())
    h = list(map(int, input().split(" ")))

    res = [ -1 ] * len(h)
    print(jump(n-1, h, res))


if __name__ == '__main__':
    main()


### FIXED CODE ###

def calc_cost(h):
    if (len(h) == 0):
        return 0

    cost = [None] * len(h)
    cost[0] = 0
    for i in range(1, len(h)):
        cost[i] = cost[i-1] + abs(h[i] - h[i-1])
        if i>1:
            cost[i] = min(cost[i], cost[i-2] + abs(h[i] - h[i-2]))

    return cost[len(h)-1]

if __name__ == "__main__":
    n = int(input())
    h = list(map(int, input().split(" ")))
    res = calc_cost(h)
    print(res)
import sys
input=sys.stdin.readline
sys.setrecursionlimit(10 ** 8)
from itertools import accumulate
from itertools import permutations
from itertools import combinations
from collections import defaultdict
from collections import Counter
import fractions
import math
from collections import deque
from bisect import bisect_left
from bisect import insort_left
import itertools
from heapq import heapify
from heapq import heappop
from heapq import heappush
import heapq
from copy import deepcopy
from decimal import Decimal
alf = list("abcdefghijklmnopqrstuvwxyz")
ALF = list("ABCDEFGHIJKLMNOPQRSTUVWXYZ")
#import numpy as np
INF = float("inf")
#d = defaultdict(int)
#d = defaultdict(list)
#N = int(input())
#A = list(map(int,input().split()))
#S = list(input())[:-1]
#S.remove("\n")
#N,M = map(int,input().split())
#S,T = map(str,input().split())
#A = [int(input()) for _ in range(N)]
#S = [list(input())[:-1] for _ in range(N)]
#A = [list(map(int,input().split())) for _ in range(N)]
A,B = map(float,input().split())
if round(A) == 0 or B <= 0.005:
    print(0)
else:
    a = int(A)
    b = Decimal(B)
    print(floor(a*b))
    

    





### FIXED CODE ###

import sys
input=sys.stdin.readline
sys.setrecursionlimit(10 ** 8)
from itertools import accumulate
from itertools import permutations
from itertools import combinations
from collections import defaultdict
from collections import Counter
import fractions
import math
from collections import deque
from bisect import bisect_left
from bisect import insort_left
import itertools
from heapq import heapify
from heapq import heappop
from heapq import heappush
import heapq
from copy import deepcopy
alf = list("abcdefghijklmnopqrstuvwxyz")
ALF = list("ABCDEFGHIJKLMNOPQRSTUVWXYZ")
#import numpy as np
INF = float("inf")
#d = defaultdict(int)
#d = defaultdict(list)
#N = int(input())
#A = list(map(int,input().split()))
#S = list(input())[:-1]
#S.remove("\n")
#N,M = map(int,input().split())
#S,T = map(str,input().split())
#A = [int(input()) for _ in range(N)]
#S = [list(input())[:-1] for _ in range(N)]
#A = [list(map(int,input().split())) for _ in range(N)]
A,B = map(float,input().split())
if math.floor(A) == 0 or B <= 0.005:
    print(0)
else:
    A = int(A)
    B *= 100.0
    B = round(B)
    c = A*B
    c = round(c)
    print(c // 100)
def main():
    s = map(int,input().split())

    ans = len(s)
    for i in range(0,len(s)-1):
        if s[i] != s[i+1]:
            ans = min(ans , max(i+1 , len(s)-i-1))
    print(ans)

if __name__ == '__main__':
    main()

### FIXED CODE ###

def main():
    s = input()

    ans = len(s)
    for i in range(0,len(s)-1):
        if s[i] != s[i+1]:
            ans = min(ans , max(i+1 , len(s)-i-1))
    print(ans)

if __name__ == '__main__':
    main()
x = int(input)
if x<30:
  print('Yes')
 else:
  print('No')

### FIXED CODE ###

x = int(input())
if x<30:
  print('No')
else:
  print('Yes')
from functools import reduce
import math
import collections

def main():
    # 文字列の2進数を数値にする
    # '101' → '5'
    # 文字列の頭に'0b'をつけてint()にわたす
    # binary = int('0b'+'101',0)

    # 2進数で立っているbitを数える
    # 101(0x5) → 2
    # cnt_bit = bin(5).count('1')
    
    # N! を求める
    # f = math.factorial(N)

    # N の逆元
    # N_inv = pow(N,MOD-2,MOD)

    # nCr
    # Nの階乗 * rの階乗の逆元 * n-rの階乗の逆元
    
    # 切り捨て
    # 4 // 3
    # 切り上げ
    #-(-4 // 3)
    
    # 初期値用:十分大きい数(100億)
    INF = float("inf")

    # 大きな素数
    MOD = 10**9+7
    
    # 1文字のみを読み込み
    # 入力:2
    # a = input().rstrip()
    # 変数:a='2'
    
    # スペース区切りで標準入力を配列として読み込み
    # 入力:2 4 5 7
    # a, b, c, d = (int(_) for _ in input().split())  
    # 変数:a=2 b=4 c=5 d =7
    
    # 1文字ずつ標準入力を配列として読み込み
    # 入力:2 4 5 7
    # a = list(int(_) for _ in input().split())
    # 変数:a = [2, 4, 5, 7]    

    # 1文字ずつ標準入力を配列として読み込み
    # 入力:2457
    # a = list(int(_) for _ in input())
    # 変数:a = [2, 4, 5, 7]    
    N = int(input())
    A = list(int(_) for _ in input().split())
    A_fixed = []
    for i in range(N):
        A_fixed.append(A[i]-i-1)
    cnt = 0
    B = A_fixed.sorted()
    b = B[N//2]
    for i in range(N):
        cnt += abs(b-A_fixed[i])
    # print(A_fixed)
    # print(b)
    print(cnt)    
    
if __name__ == '__main__':
    main()


### FIXED CODE ###

from functools import reduce
import math
import collections

def main():
    # 文字列の2進数を数値にする
    # '101' → '5'
    # 文字列の頭に'0b'をつけてint()にわたす
    # binary = int('0b'+'101',0)

    # 2進数で立っているbitを数える
    # 101(0x5) → 2
    # cnt_bit = bin(5).count('1')
    
    # N! を求める
    # f = math.factorial(N)

    # N の逆元
    # N_inv = pow(N,MOD-2,MOD)

    # nCr
    # Nの階乗 * rの階乗の逆元 * n-rの階乗の逆元
    
    # 切り捨て
    # 4 // 3
    # 切り上げ
    #-(-4 // 3)
    
    # 初期値用:十分大きい数(100億)
    INF = float("inf")

    # 大きな素数
    MOD = 10**9+7
    
    # 1文字のみを読み込み
    # 入力:2
    # a = input().rstrip()
    # 変数:a='2'
    
    # スペース区切りで標準入力を配列として読み込み
    # 入力:2 4 5 7
    # a, b, c, d = (int(_) for _ in input().split())  
    # 変数:a=2 b=4 c=5 d =7
    
    # 1文字ずつ標準入力を配列として読み込み
    # 入力:2 4 5 7
    # a = list(int(_) for _ in input().split())
    # 変数:a = [2, 4, 5, 7]    

    # 1文字ずつ標準入力を配列として読み込み
    # 入力:2457
    # a = list(int(_) for _ in input())
    # 変数:a = [2, 4, 5, 7]    
    N = int(input())
    A = list(int(_) for _ in input().split())
    A_fixed = []
    for i in range(N):
        A_fixed.append(A[i]-i-1)
    cnt = 0
    A_fixed.sort()
    b = A_fixed[N//2]
    for i in range(N):
        cnt += abs(b-A_fixed[i])
    # print(A_fixed)
    # print(b)
    print(cnt)    
    
if __name__ == '__main__':
    main()
MOD=10**9+7

N=int(input())
C=list(map(int, input().split()))
C.sort(reverse=True)
out=0
tmp1=pow(2, N-1, MOD)
tmp2=pow(2, N-2, MOD)
for i in range(N):
  out+=(tmp1+tmp2*i)*C[i]
  out%=MOD
  
out=out*pow(2, N, MOD)
print(int(out%MOD))

### FIXED CODE ###

MOD=10**9+7

N=int(input())
if N==1:
  C=int(input())
  print(2*C%MOD)
  exit()
C=list(map(int, input().split()))
C.sort(reverse=True)
out=0
tmp1=pow(2, N-1, MOD)
tmp2=pow(2, N-2, MOD)
for i in range(N):
  out+=(tmp1+tmp2*i)*C[i]
  out%=MOD
  
out=out*pow(2, N, MOD)
print(int(out%MOD))
a=int(input())
b=int(input())
if a>b:
  print(2*a-1)
else if a=b:
  print(2*a)
else:
  print(2*b-1)

### FIXED CODE ###

a,b=map(int, input().split())
if a>b:
  print(2*a-1)
elif a==b:
  print(2*a)
else:
  print(2*b-1)
#-*-coding:utf-8-*-

def is_all_odd(lists):
    odd_flag = 1
    for i in lists:
        if i % 2 != 0:
            odd_flag *= 1
        else:
            odd_flag *= 0
    if odd_flag == 1:
        return True
    else:
        return False

def main():
    #入力
    N = int(input())
    a = list(map(int, input().split()))
    print(a)

    #変数
    count = 0

    while not is_all_odd(a):
        devide_flag = 0
        for i in range(N):
            if a[i] % 2 == 0 and devide_flag == 0:
                a[i] = int(a[i]/2) 
                devide_flag = 1
            else:
                a[i] = a[i] * 3
        count += 1
        print(a)
    
    print(count)




if __name__ == '__main__':
    main()

### FIXED CODE ###

#-*-coding:utf-8-*-

def main():
    #入力
    N = int(input())
    a = list(map(int, input().split()))

    #変数
    count = 0

    for i in a:
        while i % 2 == 0:
            i /= 2
            count += 1 
            
    print(count)
 
if __name__ == '__main__':
    main()
while True:
    N = input()
    if N == "0000":
        break
    ans = 0
    if int(N) % 1111 == 0:
        print("NA")
        continue
    while int(N) != 6174:
        a, b, c, d = N[0], N[1], N[2], N[3]
        S =  sorted([a, b, c, d])
        L = int([''.join(S[::-1])][0])
        S = int([''.join(S)][0])
        ans += 1
        N = str(L-S)
    print(ans)

### FIXED CODE ###

while True:
    N = input()
    if N == "0000":
        break
    ans = 0
    if int(N) % 1111 == 0:
        print("NA")
        continue
    while N != '6174':
        N = list(N)
        S = int(''.join(sorted(N)))
        L = int(''.join(sorted(N)[::-1]))
        ans += 1
        N = str(L-S).zfill(4)
    print(ans)
S = input()
T = input()

cur = T.find(S[0])
i = 0
con = len(S)

while con != 0:
  if S[i] == T[cur]:
    con -= 1
    
    if con == 0:
      print("Yes")
    
    i += 1
    if cur == (len(S) - 1):
      cur = 0
    else:
      cur += 1
  else:
    print("No")
    break



### FIXED CODE ###

A = list(map(int,input().split()))

ans = (max(A) - min(A))

print(ans)
#include <iostream>
#include <math.h>
#include <string>
#include <vector>
#include <fstream>
#include <algorithm>
using namespace std;

int main() {
    unsigned long long a,k;
    float b;
    cin>>a>>b;
    k=trunc(a*b);
    cout<<k;
    return 0;
}

### FIXED CODE ###

import math
from decimal import *
getcontext().prec = 100
a,b=input().split()
a=int(a)
print(int(a*Decimal(b)))
dic = {}
for i in xrange(97, 123):
  dic.setdefault(chr(i), 0)

input = raw_input()
flag = False
while input != "":
  for i in xrange(len(input)):
    if input[i].lower() in dic:
      dic[input[i].lower()] += 1
    elif input[i] == ".":
      flag = True
      break
  if flag == True:
    break
  input = raw_input()

  # print dic
for i in xrange(97, 123):
  print chr(i) + " : " + str(dic[chr(i)])

### FIXED CODE ###

import sys

dic = {}
for i in xrange(97, 123):
  dic.setdefault(chr(i), 0)

line = ""
while True:
  try:
    temp = raw_input()
    # print "temp = " + temp
    if temp != "":
      line += temp
    else:
      break
  except:
    break

# print line

for i in xrange(len(line)):
  try:
    if line[i].lower() in dic:
      dic[line[i].lower()] += 1
  except TypeError:
    continue

  # print dic
for i in xrange(97, 123):
  print chr(i) + " : " + str(dic[chr(i)])
import itertools
N = int(input())
L = list(map(int, input().split()))
num = []
ans = 0

for i in itertools.permutations(L, r=3):
    i = list(i)
    i.sort()
    if i not in num:
        num.append(i)

for i in range(len(num)):
    if num[i][0] + num[i][1] > num[i][2]　and num[i][1] + num[i][2] > num[i][0] and num[i][0] + num[i][2] > num[i][1]:
        ans += 1
print(ans)


### FIXED CODE ###

A, B = map(int, input().split())
B *= 2

if B >= A:
    print(0)

else:
    print(A-B)
import itertools
def f(a):
 if len(a)<2:yield(a[0],a[0])
 for i in range(1,len(a)):
  for p,s in f(a[:i]):
   for q,t in f(a[i:]):
    yield(p+q,f'({s}+{t})')
    yield(p-q,f'({s}-{t})')
    yield(p*q,f'({s}*{t})')
def s(a):
 for p in itertools.permutations(a):
  for n,s in f(p):
   if n==10:print(s);return 1
while 1:
 a=list(map(int,input().split()))
 if sum(a)and not s(a):print(0)


### FIXED CODE ###

from itertools import *
g=lambda a,x,b:{'+':a+b,'-':a-b,'*':a*b}[x]
def f(s):
 for a,b,c,d in permutations(s):
  for x,y,z in product('+-*',repeat=3):
   if g(g(g(a,x,b),y,c),z,d)==10:return f"(({a}{x}{b}){y}{c}){z}{d}"
   if g(g(a,x,b),y,g(c,z,d))==10:return f"({a}{x}{b}){y}({c}{z}{d})"
 return 0
for e in iter(input,'0 0 0 0'):print(f(list(map(int,e.split()))))
p=[list(map(int,input().split()) for i in range(2))]

(p[0][0]-p[1][0])*(p[0][1]-p[1][1])

### FIXED CODE ###

p=[list(map(int,input().split())) for i in range(2)]

print((p[0][0]-p[1][0])*(p[0][1]-p[1][1]))