Harryxun/stf_run huggingface dataset:
n = int(input())
LST = [0] * n
for i in range(n):
    p = int(input()) # people num
    lst = [[0]*2 for _ in range(p)]
    for j in range(p):
        a, b = list(map(int, input().split())) # talk
        lst[j][0] = a - 1 # 0-indexed
        lst[j][1] = b
    LST[i] = lst

def checker(bit):
    flag = True
    # i番目の人が正直者かどうかをチェック
    for i in range(n):
        # i番目の人が正直者でないなら発言の真偽は両方の可能性があるので無視する
        if not ((bit >> 2-i) & 1):
            continue
        # i番目の人が正直なので発言を見にいく
        num = len(LST[i])  # 何人について発言しているか
        for j in range(num):
            people = LST[i][j][0] # i番目の人のj個目の発言の対象者
            TF = LST[i][j][1] # i番目の人のj個目の発言の対象者が0(=正直者でない)なのか1(=正直者)
            if TF == 0 and ((bit >> 2-people) & 1) == 1:
                flag = False
            if TF == 1 and ((bit >> 2-people) & 1) != 1:
                flag = False
    return flag

max_num = 0
for k in range(n ** 2 - 1):
    cnt = 0
    if checker(k):
        # bitの中で1が立っている(=正直者)をカウント
        for l in range(n):
            if((k >> l) & 1):
                cnt += 1
        if cnt > max_num:
            max_num = cnt

print(max_num)

### FIXED CODE ###

n = int(input())
words_list = [[] for _ in range(n)]
for i in range(n):
    a = int(input())
    for _ in range(a):
        x, y = map(int, input().split())
        words_list[i].append((x - 1, y))

ans = 0
for i in range(2 ** n):
    peoples = []
    flag = True
    for j in range(n):
        if (i >> j & 1):
            peoples.append(1)
        else:
            peoples.append(0)
    for k in range(n):
        if peoples[k] == 1:
            words = words_list[k]
            for word in words:
                if peoples[word[0]] != word[1]:
                    flag = False
                    break
    if flag:
        ans = max(ans, sum(peoples))

print(ans)
n, m = map(int, input().split())
edges = [list(map(lambda x: int(x) - 1, input().split())) for _ in range(m)]
edges += [[i, i] for i in range(n)]

q = int(input())
color = [0] * q
dp = [[0 for j in range(n)] for i in range(11)]
for i in range(q):
    v, d, color[i] = map(int, input().split())
    dp[d][v - 1] = i
 
for i in reversed(range(1, 11)):
    for u, v in edges:
        dp[i - 1][u] = max(dp[i - 1][u], dp[i][v])
        dp[i - 1][v] = max(dp[i - 1][v], dp[i][u])
 
print(*[color[dp[0][i]] for i in range(n)], sep = '\n')

### FIXED CODE ###


n, m = map(int, input().split())
edges = [list(map(lambda x: int(x) - 1, input().split())) for _ in range(m)]

q = int(input())
vv = [None] * q
dd = [None] * q
cc = [None] * q
dp = [[-1 for j in range(11)] for i in range(n)]
for i in range(q):
    vv[i], dd[i], cc[i] = map(int, input().split())
    dp[vv[i] - 1][dd[i]] = i

for i in reversed(range(1, 11)):
    for j in range(n):
        dp[j][i - 1] = max(dp[j][i - 1], dp[j][i])
    for u, v in edges:
        dp[u][i - 1] = max(dp[u][i - 1], dp[v][i])
        dp[v][i - 1] = max(dp[v][i - 1], dp[u][i])

for i in range(n):
    if dp[i][0] == -1:
        print('0')
    else:
        print(cc[dp[i][0]])
n,m=map(int,input().split())
mat=[]
for i in range(n):
    mat.append(list(input()))
mat.sort(key=lambda x:x)
ans=''
for i in mat:
    ans+=i 
print(ans) 

### FIXED CODE ###

n,m=map(int,input().split())
mat=[]
for i in range(n):
    mat.append(input())
mat.sort(key=lambda x:x)
ans=''
for i in mat:
    ans+=i 
print(ans)
def binary_serch(target, num_list):
    ok = len(num_list)
    ng = -1

    while(abs(ok - ng) > 1):
        mid = int((ok + ng) / 2)
        mid_num = num_list[mid]
        if target < mid_num:
            ok = mid
        else:
            ng = mid

    return ok


if __name__ == '__main__':
    N = int(input())
    A = [int(i) for i in input().split()]
    B = [int(i) for i in input().split()]
    C = [int(i) for i in input().split()]

    A.sort()
    B.sort()
    C.sort()

    # index
    A2B = [binary_serch(a, B) for a in A]

    # 累積和
    B2C = []
    tmp = 0
    for b in B[::-1]:
        tmp = tmp + (N - binary_serch(b, C))
        B2C.append(tmp)

    B2C = B2C[::-1]

    ans = 0

    for i in range(N):
        ans += B2C[A2B[i]]

    print(ans)


### FIXED CODE ###

def binary_serch(target, num_list):
    ok = len(num_list)
    ng = -1

    while(abs(ok - ng) > 1):
        mid = int((ok + ng) / 2)
        mid_num = num_list[mid]
        if target < mid_num:
            ok = mid
        else:
            ng = mid

    return ok


if __name__ == '__main__':
    N = int(input())
    A = [int(i) for i in input().split()]
    B = [int(i) for i in input().split()]
    C = [int(i) for i in input().split()]

    A.sort()
    B.sort()
    C.sort()

    # index
    A2B = [binary_serch(a, B) for a in A]

    # 累積和
    B2C = []
    tmp = 0
    for b in B[::-1]:
        tmp = tmp + (N - binary_serch(b, C))
        B2C.append(tmp)

    B2C = B2C[::-1]

    ans = 0

    for i in range(N):
        if not A2B[i] == N:
            ans += B2C[A2B[i]]

    print(ans)
import sys

def debug(*args):
    print(*args, file=sys.stderr)

# https://www.themathpage.com/Alg/difference-two-squares-2.htm#fifth

# https://qiita.com/snow67675476/items/e87ddb9285e27ea555f8
def factorize(n):
    arr = []
    temp = n
    for i in range(2, int(-(-n**0.5//1))+1):
        if temp%i==0:
            cnt=0
            while temp%i==0:
                cnt+=1
                temp //= i
            arr.append([i, cnt])

    if temp!=1:
        arr.append([temp, 1])

    if arr==[]:
        arr.append([n, 1])

    return arr

def get_factors_of(a_number):
    factorized = factorize(a_number)
    return [factor for factor, _ in factorized]


x_diff_of_5th_factor = int(input())

factors_of_x = get_factors_of(x_diff_of_5th_factor)

# debug(factors_of_x)

for a_factor_of_x in factors_of_x:
    for a in range(a_factor_of_x//2+1):
        b = a - a_factor_of_x

        if a ** 5 - b ** 5 == x_diff_of_5th_factor:
            print('{} {}'.format(a, b))
            sys.exit(0)
sys.exit(1)


### FIXED CODE ###

import sys

def debug(*args):
    print(*args, file=sys.stderr)


x_diff_of_5th_factor = int(input())


for a in range(-118, 119):
    for b in range(-119, 118):
        if a ** 5 - b ** 5 == x_diff_of_5th_factor:
            print('{} {}'.format(a, b))
            sys.exit(0)

sys.exit(1)
string=list(input())
if int(string[1])==0:
  c=1
else:
  c=0
a=0
for s in string:
  if int(s)==0 and c==1:
    c-=1
  elif int(s)==0 and c==0:
    c+=1
    a+=1
  elif int(s)==1 and c==0:
	c+=1
  elif int(s)==1 and c==1:
	c-=1
    a+=1
print(a)

### FIXED CODE ###

string=list(input())
if int(string[0])==1:
    c=0
else:
    c=1
a=0
for s in string:
    if int(s)==0 and c==1:
        c-=1
    elif int(s)==0 and c==0:
        c+=1
        a+=1
    elif int(s)==1 and c==0:
        c+=1
    elif int(s)==1 and c==1:
        c-=1
        a+=1
print(a)
a=list(map(int,input().split()))
print(min(a[0]*a[1],a[2])
      

### FIXED CODE ###

a=list(map(int,input().split()))
print(min(a[0]*a[1],a[2]))
L = int(input())

num = L // 3
rem = x % 3

if rem == 1:
    res = (num+1)*(num**2)

elif rem == 2:
    res = ((num + 1) ** 2) * num

else:
    res = num ** 3

res2 = (x/3)**3
if res > res2:
    print(res)
else:
    print(res2)

### FIXED CODE ###

L = int(input())

num = L // 3
rem = L % 3

if rem == 1:
    res = (num+1)*(num**2)

elif rem == 2:
    res = ((num + 1) ** 2) * num

else:
    res = num ** 3

res2 = (L/3)**3
if res > res2:
    print(res)
else:
    print(res2)
N, M = map(int, input().split())
A = []
B = []
P = [[] for _ in range(N)]
C = [[] for _ in range(N)]
for i in range(N-1+M):
    a, b = map(int, input().split())
    C[a-1].append(b-1)
    P[b-1].append(a-1)


# print(P)
# print(C)

dp = [-1] * N
def calc(i):
    if dp[i] >= 0:
        return dp[i]
    if not P[i]:
        dp[i] = 0
        return 0
    ma = -1
    for p in P[i]:
        ma = max(ma, calc(p))
    dp[i] = ma+1
    return ma+1

for i in range(N):
    calc(i)

for i in range(N):
    if dp[i] == 0:
        print(0)
    else:
        for p in P[i]:
            if dp[p] == dp[i] - 1:
                print(p+1)
                break
                


### FIXED CODE ###

import sys
sys.setrecursionlimit(300000)

N, M = map(int, input().split())
A = []
B = []
P = [[] for _ in range(N)]
C = [[] for _ in range(N)]
for i in range(N-1+M):
    a, b = map(int, input().split())
    C[a-1].append(b-1)
    P[b-1].append(a-1)


# print(P)
# print(C)

dp = [-1] * N
def calc(i):
    if dp[i] >= 0:
        return dp[i]
    if not P[i]:
        dp[i] = 0
        return 0
    ma = -1
    for p in P[i]:
        ma = max(ma, calc(p))
    dp[i] = ma+1
    return ma+1

for i in range(N):
    calc(i)

for i in range(N):
    if dp[i] == 0:
        print(0)
    else:
        for p in P[i]:
            if dp[p] == dp[i] - 1:
                print(p+1)
                break
from collections import deque, namedtuple
import sys
sys.setrecursionlimit(100000000)

class RootedTree:
    def __init__(self, t, n):
        self.t = t
        self.n = n
        self.d = [-1] * n
    def setDepth(self, u, p):
        self.d[u] = p
        if self.t[u].r != -1:
            self.setDepth(self.t[u].r, p)
        if self.t[u].l != -1:
            self.setDepth(self.t[u].l, p + 1)
        return(self.d)
    def getChildren(self, u):
        ret = []
        c = self.t[u].l
        while c != -1:
            ret.append(c)
            c = self.t[c].r
        return(ret)
    def printNode(self, i):
        p_ = self.t[i].p
        d_ = self.d[i]
        c_ = self.getChildren(i)
        if p_ == -1:
            t_ = "root"
        elif len(c_) == 0:
            t_ = "leaf"
        else:
            t_ = "internal node"
        print("node {}: parent = {}, depth = {}, {}, {}".format(i, p_, d_, t_, c_))

if __name__ == '__main__':
    n = int(input().rstrip())
    Node = namedtuple('Node', ['p', 'l', 'r'])
    t = [Node(-1, -1, -1)] * n
    r = -1
    for i in range(n):
        tmp = deque([int(i) for i in input().rstrip().split(" ")])
        v = tmp.popleft()
        d = tmp.popleft()
        for j in range(d):
            c = tmp.popleft()
            if j == 0:
                t[v] = t[v]._replace(l = c)
            else:
                t[l] = t[l]._replace(r = c)
            l = c
            t[c] = t[c]._replace(p = v)
    for i in range(n):
        if (t[i].p == -1):
            r = i
    x = RootedTree(t, n)
    x.setDepth(r, 0)
    for i in range(n):
        x.printNode(i)
    

### FIXED CODE ###

from collections import deque, namedtuple

class RootedTree:
    def __init__(self, t, n):
        self.t = t
        self.n = n
        self.d = [-1] * n

    def setDepth(self, u, p):
        self.t[u] = self.t[u]._replace(d = p)
        for i in self.getChildren(u):
            self.setDepth(i, p + 1)

    def getChildren(self, u):
        ret = []
        c = self.t[u].l
        while c != -1:
            ret.append(c)
            c = self.t[c].r
        return(ret)

    def printNode(self, i):
        p_ = self.t[i].p
        d_ = self.t[i].d
        c_ = self.getChildren(i)
        if p_ == -1:
            t_ = "root"
        elif len(c_) == 0:
            t_ = "leaf"
        else:
            t_ = "internal node"
        print("node {}: parent = {}, depth = {}, {}, {}".format(i, p_, d_, t_, c_))

if __name__ == '__main__':
    n = int(input().rstrip())
    Node = namedtuple('Node', ['p', 'l', 'r', 'd'])
    t = [Node(-1, -1, -1, -1)] * n
    r = -1
    for i in range(n):
        tmp = deque([int(i) for i in input().rstrip().split(" ")])
        v = tmp.popleft()
        d = tmp.popleft()
        for j in range(d):
            c = tmp.popleft()
            if j == 0:
                t[v] = t[v]._replace(l = c)
            else:
                t[l] = t[l]._replace(r = c)
            l = c
            t[c] = t[c]._replace(p = v)
    for i in range(n):
        if (t[i].p == -1):
            r = i
    x = RootedTree(t, n)
    x.setDepth(r, 0)
    for i in range(n):
        x.printNode(i)
w,h,x,y = map(int,input().split())

print(w*h/2,end = ' ')
if w/2==x and h/2==y:
    pirnt('1')
else:
    print('0')

### FIXED CODE ###

w,h,x,y = map(int,input().split())

print(w*h/2,end = ' ')
if w/2==x and h/2==y:
    print('1')
else:
    print('0')
import sys

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

factor = {}
tmp = 2
while(M // tmp >= 1):
    if(M % tmp != 0):
        if(tmp == 2):
            tmp += 1
        elif(M // tmp < tmp):
            tmp = M
        else:
            tmp += 2
        continue

    M = M // tmp
    factor[tmp] = factor.get(tmp, 0) + 1

if(factor == {}):
    pimport sys

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

factor = {}
tmp = 2
while(M // tmp >= 1):
    if(M % tmp != 0):
        if(tmp == 2):
            tmp += 1rint(1)
    sys.exit()

ans = 1
max_a = 7 + 10 ** 9
max_value = max(list(factor.values()))
aho = {0: 1}
fact = {0: 1}
abc = {}
for i in range(1, max_value + 1):
    # print(i)
    aho[i] = ((aho[i - 1] * (i + N - 1)))
    fact[i] = (fact[i - 1] * i)
    abc[i] = (aho[i] // fact[i]) % max_a


# print(factor)
# print(aho, fact)
for i in factor.values():
    # print(i)
    ans = (ans * abc[i]) % max_a
print(ans)

### FIXED CODE ###

import sys

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

factor = {}
tmp = 2
while(M // tmp >= 1):
    if(M % tmp != 0):
        if(tmp == 2):
            tmp += 1
        elif(M // tmp < tmp):
            tmp = M
        else:
            tmp += 2
        continue

    M = M // tmp
    factor[tmp] = factor.get(tmp, 0) + 1

if(factor == {}):
    print(1)
    sys.exit()

ans = 1
max_a = 7 + 10 ** 9
max_value = max(list(factor.values()))
aho = {0: 1}
fact = {0: 1}
abc = {}
for i in range(1, max_value + 1):
    # print(i)
    aho[i] = ((aho[i - 1] * (i + N - 1)))
    fact[i] = (fact[i - 1] * i)
    abc[i] = (aho[i] // fact[i]) % max_a


# print(factor)
# print(aho, fact)
for i in factor.values():
    # print(i)
    ans = (ans * abc[i]) % max_a
print(ans)
A,B = int(input())
x = (B-A)/(A-1)+1
print(x)

### FIXED CODE ###

A,B = map(int,input().split())
N = -(-(B-A)//(A-1)) + 1
print(N)
import numpy as np
 
N, K = map(int, input().split())
 
def get_x(n, K):
    if n >= K:
        return 0
    else:
      	x_raw = (np.log(K) - np.log(n))/np.log(2)
        # x_raw = np.log2(K) - np.log2(n)
        return np.ceil(x_raw)

def get_prob(n, K):
    x = get_x(n, K)
    if x == 0:
        return 1
    else:
        return (1/2)**x
    
ans = np.mean([get_prob(n, K) for n in range(1, N+1)])
 
print(ans)

### FIXED CODE ###

import numpy as np
 
N, K = map(int, input().split())
 
def get_x(n, K):
    if n >= K:
        return 0
    else:
        x_raw = np.log2(K) - np.log2(n)
        return np.ceil(x_raw)

def get_prob(n, K):
    x = get_x(n, K)
    if x == 0:
        return 1
    else:
        return (1/2)**x
    
ans = np.mean([get_prob(n, K) for n in range(1, N+1)], dtype=np.float64)
 
print('{0:.12f}'.format(ans))
a=[]
i=1
k=0
l=0
rk=[]
bk=[]
a.append(int(x))
for x in input().split(" "):
    a.append(int(x))

while k<=100000:
    while i<=a[0]:
        if a[i]>=k:
            rk.append(a[i])
        else:
            bk.append(a[i])
        i+=1
    if len(rk)==len(bk):
        l+=1
    rk=[]
    bk=[]
    i=1
    k+=1
        
print(l)


### FIXED CODE ###

n=0
a=[]
i=1
ii=1
l=0
tasu=0
rk=[]
bk=[]
n=int(input())
for x in input().split(" "):
    a.append(int(x))

a.sort()

print(a[int(len(a)/2)]-a[int(len(a)/2)-1])
A, B, K = map(int, input().split())

yakusuu=[]
yakusuuA = []
yakusuuB = []
for i in range(1,A+1):
  if A% i == 0:
    yakusuuA.append(i)
  
for j in range(1,B+1):
  if B%j == 0:
    yakusuuB.append(j)
    
yakusuu = set(yakusuuA) & set(yakusuuB)
yakusuu.append(1)     
print(sorted(yakusuu)[K])

  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  

### FIXED CODE ###

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

yakusuu=[]
yakusuuA = []
yakusuuB = []
for i in range(1,A+1):
  if A% i == 0:
    yakusuuA.append(i)
  
for j in range(1,B+1):
  if B%j == 0:
    yakusuuB.append(j)
    
yakusuu = list(set(yakusuuA) & set(yakusuuB))
yakusuu.append(1)     
print(sorted(yakusuu, reverse=True)[K-1])
import math

inputs = inout().split(" ")

print(math.cell(inputs[2]/(inputs[0]+inputs[1]/7))


### FIXED CODE ###

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

days = int(C/(A+(B/7)))

while 1:
    coins = A* days + B * (days//7)

    if ( coins >= C):
        break
    else:
        days += 1

print(days)
n=int(input())
bb=list(map(int,input().split()))
aa=[0]*n
for i in range(n-1):
  aa[i]=max(a[i],bb[i])
  aa[i+1]=max(a[i+1],bb[i])
print(sum(aa))

### FIXED CODE ###

n=int(input())
bb=list(map(int,input().split()))
aa=[0]*n
aa[0]=bb[0]
for i in range(n-1):
  aa[i]=min(aa[i],bb[i])
  aa[i+1]=max(aa[i+1],bb[i])
print(sum(aa))
import sys
sys.setrecursionlimit(10**6)

n = int(input())
#b = list(map(int, input().split()))
#n, m = map(int, input().split())
#s = input()
#s,t = input().split()
#a = [int(input()) for _ in range(n)]
#
#readline = sys.stdin.readline
#n,m = [int(i) for i in readline().split()]
#ab = [[int(i) for i in readline().split()] for _ in range(n)]

MAX_N = 1000000000000001

d = {(i-97+1):chr(i) for i in range(97,97+26)}

l = []

while n > 0:
    tmp = n%26
    l.append(tmp)
    n -= tmp
    n //= 26

ans = ''

for i in l[::-1]:
    ans += d[i]
    
print(ans)

### FIXED CODE ###

import sys
sys.setrecursionlimit(10**6)

n = int(input())

d = {(i-97+1):chr(i) for i in range(97,97+26)}
d[0] = 'z'

l = []

while n > 0:
    tmp = n%26
    l.append(tmp)
    if tmp == 0:
        n = n//26-1
    else:
        n //= 26

ans = ''

for i in l[::-1]:
    ans += d[i]
    
print(ans)
n,k=map(int,input().split())
A=list(map(int,input().split()))
A=list(map(lambda x:x-1,A))

next=0
hoge=[]
for i in range(k):
    next=A[next]
    if next in hoge:
        t=next
        break
    else:
        hoge.append(next)

for i in range(len(hoge)):
    if hoge[i]==t:
        hoge_1=hoge[:i]
        hoge_2=hoge[i:]

if k<=len(hoge_1):
    ans = 0
    for i in range(k):
        ans=A[ans]
else:
    k=k-len(hoge_1)-1
    k=k%len(hoge_2)
    ans=hoge_2[0]
    for i in range(k):
        ans=A[ans]


print(ans+1)

### FIXED CODE ###

n,k=map(int,input().split())
A=list(map(int,input().split()))
A=list(map(lambda x:x-1,A))

next=0
hoge=[]
zisyo={}

for i in range(n):
    next=A[next]
    if next in zisyo:
        t=next
        break
    else:
        zisyo[next]=1
        hoge.append(next)
hoge_1=[]
hoge_2=[]
for i in range(len(hoge)):
    if hoge[i]==t:
        hoge_1=hoge[:i]
        hoge_2=hoge[i:]

ans=0
if k<=len(hoge_1):
    for i in range(k):
        ans=A[ans]
else:
    k=k-len(hoge_1)-1
    k=k%len(hoge_2)
    ans=hoge_2[0]
    for i in range(k):
        ans=A[ans]


print(ans+1)
a, b, c = map(int, input().split())

if abs(a - b) < abs(a - c) and abs(a - b) < abs(b - c):
    print(abs(a - b) + abs(b - c))
elif abs(a - c) < abs(a - b) and abs(a - c) < abs(b - c):
    print(abs(a - c) + abs(b - c)
else:
    print(abs(a - c) + abs(a - b))


### FIXED CODE ###

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

a.sort()

print(a[2]-a[0])
import math
jishin, hunshin, hour, minute = map(float, input().split())

x_ji = jishin * math.cos(math.radian(hour * 360 / 12))
y_ji = jishin * math.sin(math.radian(hour * 360 / 12))
x_hun = hunshin  * math.cos(math.radian(minute * 360 / 60))
y_hun = hunshin  * math.sin(math.radian(minute * 360 / 60))

kyori = math.sqrt((x_ji - x_hun) ** 2 - (y_ji - y_hun) ** 2)
print(kyori)

### FIXED CODE ###

import math
jishin, hunshin, hour, minute = map(float, input().split())

x_ji = jishin * math.cos(math.radians((hour + minute / 60) * 360 / 12))
y_ji = jishin * math.sin(math.radians((hour + minute / 60) * 360 / 12))
x_hun = hunshin  * math.cos(math.radians(minute * 360 / 60))
y_hun = hunshin  * math.sin(math.radians(minute * 360 / 60))

kyori = math.sqrt((x_ji - x_hun) ** 2 + (y_ji - y_hun) ** 2)
print(kyori)
import sys

input_line = sys.stdin.read()
    
ch=['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']

sl=input_line.lower()

for c in ch:
    print("{} : {}".format(c,s.count(c)))

### FIXED CODE ###

s = ""
while True:
    try:
        sent = input()
    except:
        break
    s += sent
    
ch=['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']

sl=s.lower()

for c in ch:
    cnt=sl.count(c)
    print("{} : {}".format(c,cnt))
n = int(input())
h = [int(i) for i in input().split()]
ans = 0
for i in range(n):
    if h[i:] = max(h[i:]):
        ans += 1
print(ans)


### FIXED CODE ###

n = int(input())
h = [int(i) for i in input().split()]
maxi = 0
ans = 0
for i in range(n):
    if maxi <= h[i]:
        ans += 1
        maxi = h[i]
print(ans)
s=input()
l=len(s)
S=str()

cnt=0
ck=0
for i in range(l):
    if ck==l-1:
        if s[ck]==S:
            break
        else:
            cnt+=1
        break
    if i==0:
        cnt=cnt+1
        S=s[0]
        ck+=1
        continue
    if s[ck]==S:
        S=s[ck]+s[ck+1]
        ck=ck+2
        cnt=cnt+1
        continue
    if s[ck]!=S:
        S=s[ck]
        ck=ck+1
        cnt=cnt+1
        continue

print(cnt)

### FIXED CODE ###

s=input()
l=len(s)
S=str()

cnt=0
ck=0

for i in range(l):
    if ck==l-1:
        if s[ck]==S:
            break
        else:
            cnt+=1
        break
    if i==0:
        cnt=cnt+1
        S=s[0]
        ck+=1
        continue
    if s[ck]==S:
        S=s[ck]+s[ck+1]
        ck=ck+2
        cnt=cnt+1
        if ck==l:
            break
        else:
            continue
    if s[ck]!=S:
        S=s[ck]
        ck=ck+1
        cnt=cnt+1
        continue

print(cnt)
A = [list(map(int, input().split())) for i in range(3)]

n = int(input())

for j in range(n):
    b = int(input())
    for j in range(3):
        if A[j][0] == b:
            A[j][0] = 0
        if A[j][1] == b:
            A[j][1] = 0
        if A[j][2] == b:
            A[j][2] = 0

if A[0][0]==A[1][1]==A[2][2]==0:
    print("Yes")
elif A[0][2]==A[1][1]==A[2][0]==0:
    print("Yes")     
elif for k in range(3):
    if A[k][0]==A[k][1]==A[k][2]==0:
        print("Yes")
    elif A[0][k]==A[1][k]==A[2][k]==0:
        print("Yes")
else:
    print("No")

### FIXED CODE ###

A1 = list(map(int, input().split()))
A2 = list(map(int, input().split()))
A3 = list(map(int, input().split()))
n = int(input())

for i in range(n):
    b = int(input())
    for j in range(3):
        if A1[j] == b:
            A1[j] = 0
        if A2[j] == b:
            A2[j] = 0
        if A3[j] == b:
            A3[j] = 0

if A1[0]==A1[1]==A1[2]==0:
    print("Yes")
    exit
elif A2[0]==A2[1]==A2[2]==0:
    print("Yes")
    exit
elif A3[0]==A3[1]==A3[2]==0:
    print("Yes")
    exit

elif A1[0]==A2[0]==A3[0]==0:
    print("Yes")
    exit
elif A1[1]==A2[1]==A3[1]==0:
    print("Yes")
    exit
elif A1[2]==A2[2]==A3[2]==0:
    print("Yes")
    exit
    
elif A1[0]==A2[1]==A3[2]==0:
    print("Yes")
    exit
elif A1[2]==A2[1]==A3[0]==0:
    print("Yes")
    exit
else:
    print("No")
n = int(input())
a = list(map(int,input().split()))
answer = [0] * n
 
for i in range(n):
  answer[a[i]] += 1
    
for i in range(n):
  print(answer[i])

### FIXED CODE ###

n = int(input())
a = list(map(int,input().split()))
answer = [0] * n

for i in range(n - 1):
  answer[a[i] - 1] += 1
    
for i in range(n):
  print(answer[i])
N = int(input())
alist = list(map(int, input().split()))
aset = set(alist)
max_num = 0
X = 0
for x in xset:
    num = len([xx for xx in alist if x == xx])
    if max_num < num:
        max_num = num
        X = x
max_num = 0
for x in [X - 1, X, X + 1]:
    num = len([xx for xx in alist if x - 1 <= xx <= x + 1])
    max_num = max(max_num, num)
print(max_num)

### FIXED CODE ###

from collections import defaultdict as dd
N = input()
a_raw = list(map(int, input().split()))
num_count = dd(int)
for item in a_raw:
    num_count[item] += 1
    num_count[item-1] += 1
    num_count[item+1] += 1
print(max(num_count.values()))
a,b = input().split()

a = int(a)
b = int(b)

d = a // b
r = a % b
f = a / b

fmt = "{v} {c} {n}"
s = fmt.
format(v = d,c = r,n = f)
print(s)

### FIXED CODE ###

a,b = input().split()

a = int(a)
b = int(b)

d = a // b
r = a % b
f = a / b
f = "{0:.8f}".format(f)

fmt = "{v} {c} {n}"
s = fmt.format(v = d,c = r,n = f)
print(s)