Harryxun/stf_run huggingface dataset:
#Cakes and Donuts
n = int(input())
print('Yes' if[1 for a in range(n//7+1) for b in range(n//4+1) if a*7+b*4=n] else 'No')

### FIXED CODE ###

n = int(input())
print("Yes" if [1 for a in range(n//7+1) for b in range(n//4+1) if a*7+b*4 == n] else "No")
N, X = map(int, input().split())
a,p=[1],[1] 
for i in range(N):
    a.append(a[i] * 2 + 3)
    p.append(p[i] * 2 + 1)
deff(N,X): #X<=0やX>a_Nを許容し解説本文から簡略化 
    if N == 0:
        return 0 if X <= 0 else 1
    elif X <= 1 + a[N-1]:
        return f(N-1, X-1)
    else:
        return p[N-1] + 1 + f(N-1, X-2-a[N-1])
print(f(N, X))

### FIXED CODE ###

N, X = map(int, input().split())
a,p=[1],[1] 
for i in range(N):
    a.append(a[i] * 2 + 3)
    p.append(p[i] * 2 + 1)
def f(N,X): #X<=0やX>a_Nを許容し解説本文から簡略化
    if N == 0:
        return 0 if X <= 0 else 1
    elif X <= 1 + a[N-1]:
        return f(N-1, X-1)
    else:
        return p[N-1] + 1 + f(N-1, X-2-a[N-1])
print(f(N, X))
import string
alphabets = string.ascii_lowercase

S = input()

if len(S) < 26:
    for i in range(26):
        if alphabets[i] not in S:
            char_idx = i
            break
    print(S + alphabets[char_idx])
elif S == 'zyxwvutsrqponmlkjihgfedcba':
    print(-1)
else:
    cont_flag = False
    for i in range(26-1):
        if S[i] > S[i+1]:
            if cont_flag == False:
                idx = i
                cont_flag = True
        else:
            cont_flag = False
            
    if idx == 0:
        for i in range(26):
            if alphabets[i] > S[idx]:
                char_idx = i
                break
        print(alphabets[char_idx])
    else:
        st = S[:idx]
        if S[idx] == 'z':
            char = S[idx-1]
            len_st = len(st)
            for i in range(26):
                if alphabets[i] not in st and alphabets[i] > char:
                    char_idx = i
                    break
            print(st[:len_st-1] + alphabets[char_idx])
        else:
            char = S[idx]
            for i in range(26):
                if alphabets[i] not in st and alphabets[i] > char:
                    char_idx = i
                    break
            print(st + alphabets[char_idx])

### FIXED CODE ###

S = input()
alpha = 'abcdefghijklmnopqrstuvwxyz'
if S == alpha[::-1]:
    print(-1)
else:
    rest = sorted(list(set(alpha) - set(S)))
    if rest:
        print(S + rest[0])
    else:
        for i in range(len(S)-1, 0, -1):
            if S[i-1] < S[i]:
                break
        rest = sorted([s for s in S[i:] if s > S[i-1]])
        print(S[:i-1] + rest[0])
n,m,c=map(int,input().split())
b=list(map(int,input().split()))
a=[list(map(int,input().split())) for i in range(n)]
ans = 0

for k in range(m):
    if a*b+c>0:
        ans += 1
    else:
        pas
print(ans)

### FIXED CODE ###

n,m,c=map(int,input().split())
b=list(map(int,input().split()))
cou=0
for i in range(n):
    a=list(map(int,input().split()))
    x=c
    for j in range(m):
        x+=a[j]*b[j]
    if x>0:
        cou+=1
print(cou)
str = input()
ans = ''
tmp = ''
for s in str:
  if (s in ['A', 'T', 'G', 'C']):
    tmp += s
    if (len(tmp) > len(ans):
        ans = tmp
  else:
    tmp = ''

print(ans)
    

### FIXED CODE ###

str = list(input())

tmp = ''
ans = ''
for s in str:
  if (s in ['A', 'T', 'G', 'C']):
    tmp += s
    if (len(tmp) > len(ans)):
      ans = tmp
  else:
    tmp = ''

print(len(ans))
s = input()
sum = 0
i = 0

while i < 9:
  sum = sum + s % 10
  s = s // 10
  i = i + 1

if s % sum = 0:
  print("Yes")
else:
  print("No")


### FIXED CODE ###

s = int(input())
s_hold = s
sum = 0
i = 0

while i < 9:
  sum = sum + s % 10
  s = s // 10
  i = i + 1

if sum == 0:
  print("Yes")
elif s_hold % sum == 0:
  print("Yes")
else:
  print("No")
a = list(str(input()))
print(s.count("1"))

### FIXED CODE ###

s = list(str(input()))
print(s.count("1"))
def main():
	a = {"SUN" : 0,
	"SAT" : 6,
	"FRI" : 5,
	"THI" : 4, 
	"WED" : 3,
	"TUE" : 2,
	"MON" : 1}
	s = input()
	print(7-a[s])
	
main()


### FIXED CODE ###

def main():
	a = {"SUN" : 0,
	"SAT" : 6,
	"FRI" : 5,
	"THU" : 4, 
	"WED" : 3,
	"TUE" : 2,
	"MON" : 1}
	s = input()
	print(7-a[s.strip()])
	
main()
az = ["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]
sum_az = [0 for x in range(26)]

while True:
    x = raw_input()
    if x:
        break
    x.lower()f
    for i in range(26):
        for j in range(len(x)):
            if x[j] == az[i]:
                sum_az[i] += 1


for i in range(26):
    print ("%s : %d" % (az[i], sum_az[i]))
                

### FIXED CODE ###

import sys
az =["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]
sum_az = [0 for x in range(26)]

for x in sys.stdin.read().lower():
    for i in range(26):
        if x == az[i]:
            sum_az[i] += 1


for i in range(26):
    print ("%s : %d" % (az[i], sum_az[i]))
N, Y = map(int, input().split())
 
for x in range(N+1):
  for y in range(N+1-x):
        if x*10000 + y*5000 + (N+1-x-y)*1000 == Y:
           print(x, y, N+1-x-y)
       else:
           print(-1,-1,-1)

### FIXED CODE ###

N, Y = map(int, input().split())
 
for x in range(N+1):
  for y in range(N+1-x):
        if x*10000 + y*5000 + (N-x-y)*1000 == Y:
           print(x, y, N-x-y)
           exit()
 
print("-1 -1 -1")
S = int(input())
A = S//100
B = S-(A*100)
if B >12:
    if  A > 13:    
        print("YYMM")
    else A <=12:
        print("MMYY")
elif 1<= B <=12:
    if A >13:
        print("YYMM")
    else A <=12:
        print("AMBIGUOUS")
else :
    print("NA")


### FIXED CODE ###

S = int(input())
A = S//100
B = S-(A*100)
if B ==0 or B >= 13:
    if 1<= A <=12:    
        print("MMYY")
    else:
        print("NA")
elif 1<= B <=12:
    if 1<= A <=12:
        print("AMBIGUOUS")
    elif A >= 13:
        print("YYMM")
    elif A == 0:      
        print("YYMM")
    else:
        print("NA")
else:
    print("NA")
#!/usr/bin/env python3
from collections import deque, Counter
from heapq import heappop, heappush
from bisect import bisect_right

def main():
    N = int(input())
    A = [None] * N
    B = [None] * N
    for i in range(N):
        A[i], B[i] = map(int, input().split())
    print(max(A[i])+B.index(max(A[i])))

if __name__ == "__main__":
    main()


### FIXED CODE ###

#!/usr/bin/env python3
from collections import deque, Counter
from heapq import heappop, heappush
from bisect import bisect_right

def main():
    N = int(input())
    A = [None] * N
    B = [None] * N
    for i in range(N):
        A[i], B[i] = map(int, input().split())
    print(max(A)+B[A.index(max(A))])

if __name__ == "__main__":
    main()
import fractions
N = int(input())
A = list(map(int, input().split()))
# まずはA[0]以外のgcdをansとしておく
ans = A[1]
for i in range(2, N):
	ans = fractions.gcd(ans, A[i])
# つぎにA[0]と他の要素の2数のgcdをリストアップし、それが一番小さくなるindexをkとする
G = [A[0]]
for j in range(1, N):
	G.append(fractions.gcd(A[0], A[j]))
k = G.index(min(G))
# A[k]以外のgcdをtmpとしておく
if k == N - 1:
	B = A[: N - 1]
elif K == 0:
	B = A[1:]
else:
	B = A[: k] + A[k + 1:]
tmp = B[0]
for l in range(1, N - 1):
	tmp = fractions.gcd(tmp, B[l])
# ansとtmpの大きい方を出力
print(max(ans, tmp))


### FIXED CODE ###

from fractions import gcd
N = int(input())
A = list(map(int, input().split()))
Asort = sorted(A)[:: -1]
L = [0] * N  #左からi番目までのgcdをメモった配列
R = [0] * N  #右からi番目までのgcdをメモった配列
L[0] = A[0]
R[0] = A[N - 1]
for i in range(1, N):
	L[i] = gcd(L[i - 1], A[i])
	R[i] = gcd(R[i - 1], A[N - 1 - i])
ans = max(L[N - 2], R[N - 2])
for j in range(1, N - 1):
	ans = max(ans, gcd(L[j - 1], R[N - j - 2]))
print(ans)
x = int(input())
ans = []

for i in range(2, 100):
    n = 2
    while i**n <= x:
        ans.append(i**n)
        n += 1

print(max(ans))

### FIXED CODE ###

x = int(input())
ans = 0


for i in range(1, 100):
    if i**2 > x:
        ans = (i - 1)**2
        break

for i in range(1, 100):
    if i**3 > x:
        ans = max(ans, (i - 1)**3)
        break

for i in range(1, 100):
    if i**5 > x:
        ans = max(ans, (i - 1)**5)
        break

for i in range(1, 100):
    if i**7 > x:
        ans = max(ans, (i - 1)**7)
        break

print(ans)
N = input()

import math

lcm = lambda a, b: a * b // math.gcd(a, b)

print(lcm(2, N))

### FIXED CODE ###

N = int(input())

if N % 2 == 0:
    print(N)
else:
    print(2*N)
import numpy as np

MOD = 10**9+7

D,T,E = input().split()
n= int(D)

arr = np.zeros((n+1,n+1),dtype=np.int16)
for i in range(3,n+1):
    arr[0,i] = 1

for i in range(1,n+1):
    sum_ = 0

### FIXED CODE ###

D,T,S = [int(i) for i in input().split()]
out = 'Yes' if D <= T * S else 'No'
print(out)
A,B = map(int,input().split())
if A % 3 == 0 or B % 3 == 0or A + B % 3 == 0:
  print("Possible")
else:
  print("Impossible")


### FIXED CODE ###

A,B = map(int,input().split())
if A % 3 == 0 or B % 3 == 0 or (A + B) % 3 == 0:
  print("Possible")
else:
  print("Impossible")
N,R=map(int,input().split())

if N >= 10:
    R' = R
else:
    R' = R + 100 * (10 - N)

print(R')

### FIXED CODE ###

N,R=map(int,input().split())

if N >= 10:
    X = R
else:
    X = R + 100 * (10 - N)

print(X)
import math
N = int(input()) 
factor = []
tmp = int(math.sqrt(N)) + 1
list = range(2,tmp)
for num in list[::-1]:
    while N % num == 0:
        N //= num
        factor.append(num)
        factor.append(N)
    if not factor:
        factor.append(N)
        factor.append(1)
    else:
        pass
    break
if 
f=sum(factor)-2
print(f)

### FIXED CODE ###

N = int(input())
import math
sqrtN = math.floor(math.sqrt(N))
list = range(1, sqrtN+1)
a=[]
for i in list[::-1]:
    while N%i == 0:
        a.append(int(i))
        a.append(int(N/i))
        break
    if not a:
        pass
    else:
        break
f = a[0]+a[1]-2
print(f)
import math

def main():

    # 1 <= a <= b <= 10^18
    # 1 <= c,d <= 10^9

    a, b, c, d = map( int, input().split())
    count = 0


    ac = -(-a // c)
    bc = b // c

    ad = -(-a // d)
    bd = b // d

    cd = int(c * d / math.gcd(c, d))
    acd = -(-a // cd)
    bcd = b // cd

    cm_num = bc - ac + 1
    dm_num = bd - ad + 1
    cdm_num = bcd - acd + 1

    count = cm_num + dm_num - cdm_num

    total = b - a + 1

    print(total - count)

if __name__ == '__main__':
    main()



### FIXED CODE ###

#import math
import fractions

def main():

    # 1 <= a <= b <= 10^18
    # 1 <= c,d <= 10^9

    a, b, c, d = map( int, input().split())
    count = 0

    ac = -(-a // c)
    bc = b // c

    ad = -(-a // d)
    bd = b // d

    cd = int(c * d / fractions.gcd(c, d))

    acd = -(-a // cd)
    bcd = b // cd

    cm_num = bc - ac + 1
    dm_num = bd - ad + 1
    cdm_num = bcd - acd + 1

    count = cm_num + dm_num - cdm_num

    total = b - a + 1

    print(total - count)

if __name__ == '__main__':
    main()
n=int(input())
line=str(input())
line=line.replace('E','0')
line=line.replace('W','1')
line=list(map(int,line))
v=0
for i in range(n-1):
  if line[i]==0 or line[i+1]==0:
    pass
  else:
    v=line[0:i].count(o)+line[i+1:n].count(1)
    break
print(v)

### FIXED CODE ###

n=int(input())
s=input()
e=s.count('E')
w=0
ans=e+w
p=0
for i in s:
  if p==1:
    w+=1
    p=0
  if i=='E':
    e-=1
  else:
    p=1
  ans=min(ans,e+w)
print(ans)
#降順ソートの方がうまくいきそう
n,m=map(int,input().split())
a=sorted(list(map(int,input().split())),reverse=True)
cs=[]
sum=0
for i in range(n):
	sum+=a[i]
	cs.append(sum)

#和が引数以上の場合をカウントする
def overX(x):
	count=0
	#両手が違う人を握るときのみ考える
	if a[0]*2<x:
		return 0
	else:
		for i in range(n):
			if a[i]+a[0]<x:
				count+=0
			else:
				lb, ub = 0, n
				#パターンAのにぶたん。左がOなので[lb,ub)で持つ。
				while ub-lb>1:
					mid=(lb+ub)//2
					if a[i]+a[mid]>=x:
						lb=mid
					else:
						ub=mid
				count+=lb+1
		return count
#print(overX(130))

#overX>=mなる最大のxを探す->xは小さい方が実現しやすいのでパターンA->[lb,ub)でもつ
lb=1 #実現しやすい方
ub=2*10**5
while ub-lb>1:
	mid=(ub+lb)//2
	if overX(mid)>=m:
		lb=mid
	else:
		ub=mid
#ub=overX(x)>=mなる最小のx。これ以上大きくするとmに満たなくなる。
maxx=lb

hp=0
#maxx+1以上の要素をすべてたす
#和がmaxx+1以上になる組み合わせの数だけhpを加え、countをインクリメントする
if a[0]*2>=maxx+1:
	for i in range(n):
		if a[i]+a[0]<maxx+1:
			break
		else:
			lb, ub = 0, n
			#パターンAのにぶたん。左がOなので[lb,ub)で持つ。
			while ub-lb>1:
				mid=(lb+ub)//2
				if a[i]+a[mid]>=maxx+1:
					lb=mid
				else:
					ub=mid
			#a[0]からa[lb]は、a[i]と足した時にx以上になり条件を満たす。
			hp+=a[i]*(lb+1)+cs[lb]
hp+=(m-overX(maxx+1))*maxx
print(hp)

### FIXED CODE ###

n,k=map(int,input().split())
r,s,p=map(int,input().split())
t=input()
points=0
renzoku=[1 for i in range(k)]
for i in range(n):
	if i<k:
		if t[i]=='r':
			points+=p
		if t[i]=='s':
			points+=r
		if t[i]=='p':
			points+=s
	else:
		if t[i]==t[i-k]:
			renzoku[i%k]+=1
			if renzoku[i%k]%2==1:
				if t[i]=='r':
					points+=p
				if t[i]=='s':
					points+=r
				if t[i]=='p':
					points+=s
		else:
			renzoku[i%k]=1
			if t[i]=='r':
				points+=p
			if t[i]=='s':
				points+=r
			if t[i]=='p':
				points+=s
print(points)
a,b,c,d = map(int, input())

if(a*b >= c*d):
    print(a*b)
else:
    print(c*d)
    


### FIXED CODE ###

a,b,c,d = map(int, input().split())

if a*b >= c*d:
    print(a*b)
else:
    print(c*d)
num_input = [input() for i in range(2)]
x = int(num_input[0].split()[0])
n = int(num_input[0].split()[1])

num_list = [int(n) for n in num_input[1].split()]
num_list.sort()

ans=x

if n!=0 and n!=1 and n!=100:
    if x in num_list:
        index=num_list.index(x)

        value_left=x-1
        value_right=x+1

        if index!=0:
            index_left=index-1
        if index!=n:
            index_right=index+1
        
        if index==0:
            ans=x-1
        elif index==n:
            if num_list[index_right-1]!=x-1:
                ans=x+1
        else:
            for i in range(n):
                if num_list[index_left]!=value_left:
                    ans=value_left
                    break
                elif num_list[index_right]!=value_right:
                    ans=value_right
                    break
                if index_left!=0:
                    index_left=index_left-1
                if index_right!=n:
                    index_right=index_right+1
                value_left=value_left-1
                value_right=value_right+1

if n==1:
    ans=x-1

if n==100:
    if x<=50:
        ans=0
    if x>50:
        ans=101

print(ans)

### FIXED CODE ###

num_input = [input() for i in range(2)]
x = int(num_input[0].split()[0])
n = int(num_input[0].split()[1])

num_list = [int(n) for n in num_input[1].split()]
num_list.sort()

ans=x

if n!=0 and n!=1 and n!=100:
    if x in num_list:
        index=num_list.index(x)

        value_left=x-1
        value_right=x+1

        if index!=0:
            index_left=index-1
        if index!=n-1:
            index_right=index+1
        
        if index==0:
            ans=x-1
        elif index==n-1:
            if num_list[index-1]==x-1:
                ans=x+1
            else:
                ans=x-1
        else:
            for i in range(n):
                if num_list[index_left]!=value_left:
                    ans=value_left
                    break
                elif num_list[index_right]!=value_right:
                    ans=value_right
                    break
                if index_left!=0:
                    index_left=index_left-1
                if index_right!=n:
                    index_right=index_right+1
                value_left=value_left-1
                value_right=value_right+1

if n==1:
    ans=x-1

if n==100:
    if x<=50:
        ans=0
    if x>50:
        ans=101

print(ans)
n = int(input())
temp = input()
h = temp.split()
for i,item in enumerate(h):
    h[i] = int(item)
dp = [0]

def rec_flog(i):
    if len(dp) > i:
        return dp[i]
    elif i >= 2:
        step1 = abs(h[i] - h[i - 1]) + rec_flog(i-1)
        step2 = abs(h[i] - h[i -2]) + rec_flog(i-2)
        dp.append(step1 if step1 <= step2 else step2)
        return dp[i]
    else :
        dp.append(h[1] - h[0])
        return dp[1]


print(rec_flog(n-1))




### FIXED CODE ###


n = int(input())
temp = input()
h = temp.split()
for i,item in enumerate(h):
    h[i] = int(item)
dp = [0]
for i,height in enumerate(h):
    if i >=2:
        step1 = dp[i - 1] + abs(height - h[i-1])
        step2 = dp[i-2] + abs(height - h[i-2])
        dp.append(step1 if step1 <= step2 else step2)
    elif i == 1:
        dp.append(abs(height - h[i-1]))

print(dp.pop())
import sys
input = sys.stdin.readline

N, M, K = map(int, input().split())
A_list = list(map(int, input().split()))
B_list = list(map(int, input().split()))

time = 0
A_num = 0
B_num = 0
while (time < K) and (A_num <= len(A_list) -1) and (B_num <= len(B_list) -1):
    A = A_list[A_num]
    B = B_list[B_num]
    if A < B:
        time += A
        A_num += 1

    elif A > B:
        time += B
        B_num += 1

    else:
        add = 1
        time += A
        while (A_list[A_num + add] == B_list[B_num + add]) and \
              (time < K):
            time += A_list[A_num + add]
            add += 1
        if A_list[A_num + add] < B_list[B_num + add]:
            A_num += add
        else:
            B_num += add
print(A_num + B_num - 1)

### FIXED CODE ###


import sys
import numpy as np
input = sys.stdin.readline

N, M, K = map(int, input().split())
A_list = list(map(int, input().split()))
B_list = list(map(int, input().split()))


A_list.insert(0, 0)
B_list.insert(0, 0)
A_cumsum = np.cumsum(A_list)
B_cumsum = np.cumsum(B_list)

time = B_cumsum[-1]
ans, j = 0, M



for i in range(N+1):
    if A_cumsum[i] > K:
        break
    while B_cumsum[j] > K - A_cumsum[i]:
        j -= 1
    ans = max(ans, i+j)
print(ans)
N, A, B = map(int, input().split())
cnt = N//(A+B)+1

br = ''
for i in range(cnt):
    br += 'b'*A + 'r'*B

br = br[:N]
print(br.count('b'))

### FIXED CODE ###

N, A, B = map(int, input().split())
cnt = N//(A+B)
res = A*cnt

if N-cnt*(A+B)>A:
    print(res+A)
else:
    print(res+N-cnt*(A+B))
from math import gcd
from fractions import Fraction
from numpy import sign
N=int(input())
d={}
mod = 10**9+7
d={}
zeros = 0
b_zero = 0
a_zero = 0
for i in range(N):
    a, b = map(int,input().split(' '))
    a, b = map(lambda x:x//gcd(a,b),[a,b])
    if a == b == 0:
        zeros += 1
    elif a == 0:
        a_zero += 1
    elif b == 0:
        b_zero += 1
    else:
        h,t=sorted([Fraction(a,b),Fraction(-b,a)])
        key = str(h)+'/'+str(t)
        d.setdefault(key,[0,0])
        if a*b > 0:
            d[key][0] += 1
        else:
            d[key][1] += 1
ans = 1
for  v in d.values():
    h,t=sorted(v)
    if h>0:
        ans *= pow(2,h,mod) + pow(2,t,mod) -1
    else:
        ans *= pow(2,t,mod)
    ans %=mod
ans += pow(2,a_zero,mod) + pow(2,b_zero,mod) + zeros -3
print(ans)

### FIXED CODE ###

from math import gcd
from collections import defaultdict
N=int(input())
mod = 10**9+7
d_1 = defaultdict(int)
d_2 = defaultdict(int)
zeros = 0

def to_irreducible(a,b):
    GCD = gcd(a,b)
    return list(map(lambda x:x//GCD,[a,b]))
for i in range(N):
    a,b=map(int,input().split(' '))
    if a==b==0:
        zeros += 1
    elif a*b >= 0 and b!=0:
        a,b = to_irreducible(abs(a),abs(b))
        d_1[(a,b)] +=1
    else:
        a,b = to_irreducible(abs(b),abs(a))
        d_1[(a,b)] +=0
        d_2[(a,b)] +=1

ans =  1

for k,v_1 in d_1.items():
    v_2 = d_2[k]
    ans *= (pow(2,v_1,mod) + pow(2,v_2,mod) -1)
    ans %= mod

print((ans+zeros-1)%mod)
# 2020-05-22
from collections import deque


def main():
    n, m, k = [int(x) for x in input().split()]
    friends = [set() for _ in range(n)]
    blocks = [set() for _ in range(n)]
    for _ in range(m):
        a, b = [int(x) - 1 for x in input().split()]
        friends[a].add(b)
        friends[b].add(a)
    for _ in range(k):
        a, b = [int(x) - 1 for x in input().split()]
        blocks[a].add(b)
        blocks[b].add(a)

    networks = {}  # The dict of networks as sets. Keys are leaders.
    net_leaders = [-1] * n  # The leaders of the networks that the ones joined.
    visited = [False] * n
    for person in range(n):
        if visited[person]:
            continue
        networks[person] = set()
        stack = deque([person])
        while stack:
            new = stack.pop()
            for adj in friends[new]:
                if visited[adj]:
                    continue
                stack.append(adj)
                networks[person].add(adj)
                visited[adj] = True
                net_leaders[adj] = person

    answers = []
    for person in range(n):
        net = networks[net_leaders[person]]
        ans = len(net) - len(friends[person]) - 1
        bb = sum(block in net for block in blocks[person])
        answers.append(ans - bb)

    print(*answers)
    return


if __name__ == '__main__':
    main()


### FIXED CODE ###

# 2020-05-22
def main():
    n, m, k = [int(x) for x in input().split()]
    friends = [set() for _ in range(n)]
    blocks = [set() for _ in range(n)]
    for _ in range(m):
        a, b = [int(x) - 1 for x in input().split()]
        friends[a].add(b)
        friends[b].add(a)
    for _ in range(k):
        a, b = [int(x) - 1 for x in input().split()]
        blocks[a].add(b)
        blocks[b].add(a)

    networks = {}  # The dict of networks as sets. Keys are leaders.
    net_leaders = [-1] * n  # The leaders of the networks that the ones joined.
    visited = [False] * n
    for person in range(n):
        if visited[person]:
            continue
        network = set()
        network_add = network.add
        stack = [person]
        stack_append = stack.append
        stack_pop = stack.pop
        while stack:
            new = stack_pop()
            visited[new] = True
            net_leaders[new] = person
            network_add(new)
            for adj in friends[new]:
                if visited[adj]:
                    continue
                stack_append(adj)
        networks[person] = network

    answers = []
    answers_append = answers.append
    for person in range(n):
        net = networks[net_leaders[person]]
        ans = len(net) - len(friends[person]) - 1
        for block in blocks[person]:
            if block in net:
                ans -= 1
        answers_append(ans)

    print(*answers)
    return


if __name__ == '__main__':
    main()
x=int,input()
print(x//3)

### FIXED CODE ###

x=int(input())
print(x//3)
import math
import sys

args = sys.argv
A = int(args[1])
P = int(args[2])

if 0<=A and P<=100 :
    Pi = math.floor((3*A +P)/2)
    print(Pi)
else :
    print("ERROR")

### FIXED CODE ###

import math

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

if 0<=A and P<=100 :
    Pi = math.floor((3*A +P)/2)
    print(Pi)
else :
    print("ERROR")
a,b=map(int,input().split())
A=[str(a)*b]
B=[str(b)*a]
if a>b:
    print(int(B))
if a<b:
    print(int(A))
if a==b:
    print(int(A))

### FIXED CODE ###

a,b=map(int,input().split())
A=[str(a)*b]
B=[str(b)*a]
if a>b:
    print(int(''.join(B)))
if a<b:
    print(int(''.join(A)))
if a==b:
    print(int(''.join(A)))