Harryxun/stf_run huggingface dataset:
import sys
input = sys.stdin.readline

from math import factorial
from itertools import combinations
from collections import Counter
from copy import deepcopy
from operator import mul
from functools import reduce

def cmb(n,r):
    r = min(n-r,r)
    if r == 0: return 1
    over = reduce(mul, range(n, n - r, -1))
    under = reduce(mul, range(1,r + 1))
    return over // under

def main():
    n = int(input())
    a = list(map(int, input().split()))
    a_c = Counter(a)
    a_c_sum = 0
    for c in a_c:
        a_c_sum += cmb(a_c[c], 2)

    for ea in a:
        if a_c[ea] <= 1:
            sa = 0
        elif a_c[ea] == 2:
            sa = 1
        else:
            sa = cmb(a_c[ea], 2) - cmb(a_c[ea] - 1, 2)
        print(a_c_sum - sa)


if __name__ == '__main__':
    main()


### FIXED CODE ###

import sys
input = sys.stdin.readline

from math import factorial
from itertools import combinations
from collections import Counter
from copy import deepcopy
from operator import mul
from functools import reduce

def cmb(n,r):
    r = min(n-r,r)
    if r == 0: return 1
    over = reduce(mul, range(n, n - r, -1))
    under = reduce(mul, range(1,r + 1))
    return over // under

def main():
    n = int(input())
    a = list(map(int, input().split()))
    a_c = Counter(a)
    a_c_sum = 0
    for c in a_c:
        if a_c[c] >= 2:
            a_c_sum += cmb(a_c[c], 2)

    for ea in a:
        if a_c[ea] <= 1:
            sa = 0
        elif a_c[ea] == 2:
            sa = 1
        else:
            sa = cmb(a_c[ea], 2) - cmb(a_c[ea] - 1, 2)
        print(a_c_sum - sa)


if __name__ == '__main__':
    main()
# -*- coding: utf-8 -*-


N, Q = list(map(int, input().split()))


class Node:
    val = 0
    children = []

    def __init__(self, val, children):
        self.val = val
        self.children = children


# 木を作る
tree = {}
for i in range(N - 1):
    a, b = list(map(int, input().split()))
    left_node = tree.get(a, False)
    if left_node:
        left_node.children.append(b)
    else:
        tree[a] = Node(0, [b])

    right_node = tree.get(b, False)
    if not right_node:
        tree[b] = Node(0, [])


def add_val_recurse(node: Node, val):
    if node:
        node.val += val
        [add_val_recurse(tree.get(child, None), val) for child in node.children]


# 木に値を詰める
for i in range(Q):
    node, val = list(map(int, input().split()))
    add_val_recurse(tree.get(node, None), val)


print(" ".join([str(tree[key].val) for key in sorted(list(tree.keys()))]))


### FIXED CODE ###

# -*- coding: utf-8 -*-
# https://atcoder.jp/contests/abc138/tasks/abc138_d


def main():
    n, q = map(int, input().split())
    values = [0] * n
    links = [[] for _ in range(n)]

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

    for _ in range(q):
        p, x = map(int, input().split())
        values[p - 1] += x

    s = [(0, -1)]
    while s:
        i, p = s.pop()
        for j in links[i]:
            if j == p:
                continue
            values[j] += values[i]
            s.append((j, i))

    print(*values)


main()
i = input()
a,b = list(map(int, l.split()))
A = a*b
print(A)

### FIXED CODE ###

a,b=map(int,input().split())
A = a*b
print(A)
num1 = int(input())
num2 = int(input())
seki = num1 * num2
print(seki)

### FIXED CODE ###

a, b = map(int, input(). split())
print(a*b)
vimport sys 
sys.setrecursionlimit(10**6)
input = lambda: sys.stdin.readline().rstrip()

def dfs(v, pv):
    # global P

    for nv in G[v]:
        if nv != pv:
            P[nv] += P[v]
            dfs(nv, v)

n,q = map(int, input().split())
G = [[] for _ in range(n)]              # adjacent list
for i in range(n-1):
    a,b = map(int, input().split())
    G[a-1].append(b-1)
    G[b-1].append(a-1)

P = [0]*n                               # add list
for i in range(q):
    p,x = map(int, input().split())
    P[p-1] += x


dfs(0, 0)
print(*P)



### FIXED CODE ###

import sys
from operator import itemgetter #sortedの対象を決めたい
from fractions import gcd #最大公約数求めたい
from math import ceil, floor, sqrt #小数点切り上げ、切り捨て、平方根求めたい
from copy import deepcopy #参照で影響されないコピーが作られる
from collections import Counter, deque #要素ごとの出現回数を数える。双方向アクセス可能データ型
import heapq
from functools import reduce
sys.setrecursionlimit(200000)

input = sys.stdin.readline
# template


n,q = map(int, input().split())

ct = [0] * (n+1)
o = [0] * (n+1)
g = [[] for _ in range(n+1)]

for i in range(n-1):
    a,b = map(int, input().split())
    g[a].append(b)
    g[b].append(a)

for i in range(q):
    p,x = map(int, input().split())
    o[p] += x

todo = [1]
seen = [False] * (n+1)
while todo:
    p = todo.pop(-1)
    ct[p] += o[p]
    seen[p] = True
    for i in g[p]:
        if seen[i]:
            ct[p] += ct[i]
        else:
            todo.append(i)

print(*ct[1:])
a,b=[int(x) for x input().split()]
if a<=b:
    print(a)
else:
    print(a-1)

### FIXED CODE ###

a,b=[int(x) for x in input().split()]
if a<=b:
    print(a)
else:
    print(a-1)
s=input()
cnt=0
for i in range(s.len()):
if(s[i]!=s[-1-i]):
cnt=cnt+1


print(cnt)

### FIXED CODE ###

given = input()
a = len(given) // 2
count = 0
for i in range(1, a + 1):
    last = given[-i]
    first = given[i - 1]
    if last != first:
        count += 1
print(count)
#ABC125C-GCDonBlackboard.py

from sys import stdin
from fractions import gcd
#from functools import lru_cache

input = stdin.readline

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

#@lru_cache(maxsize=None)
def L(i):
    if i == 0:
        return 0
    else:
        return gcd(L(i-1),A[i-1])

#@lru_cache(maxsize=None)
def R(i):
    if i == N:
        return 0
    else:
        return gcd(R(i+1),A[i])

M = []

for i in range(N):
    M.append(gcd(L(i), R(i+1)))

print(max(M))


### FIXED CODE ###

#ABC125C-GCDonBlackboard.py

from sys import stdin
from sys import setrecursionlimit
#import random
from fractions import gcd
from functools import lru_cache

setrecursionlimit(1000000)

input = stdin.readline

N = int(input())
A = list(map(int, input().split()))
#A = [random.randrange(1,10**9) for _ in range(N)]

@lru_cache(maxsize=None)
def L(i):
    if i == 0:
        return 0
    else:
        return gcd(L(i-1),A[i-1])

@lru_cache(maxsize=None)
def R(i):
    if i == N:
        return 0
    else:
        return gcd(R(i+1),A[i])

M = []

for i in range(N):
    M.append(gcd(L(i), R(i+1)))

print(max(M))
import queue

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

graph = [[] for i in range(N)]

for i in range(M):
    A, B = map(int, input().split())
    A -= 1
    B -= 1
    graph[A].append(B)
    graph[B].append(A)

dist = [-1 for i in range(N)]
que = queue.Queue()

dist[0] = 0
que.put(0)


while not que.empty():
    v = que.get()
    for nv in graph[v]:
        if dist[nv] != -1:
            continue

        dist[nv] = dist[v] + 1
        que.push(nv)


print("Yes")
for i in range(1, N):
    print(v[i] + 1)


### FIXED CODE ###

import queue

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

graph = [[] for i in range(N)]
for i in range(M):
    A, B = map(int, input().split())
    A -= 1
    B -= 1
    graph[A].append(B)
    graph[B].append(A)

# 各部屋に設定する番号を記録する
v = [-1 for i in range(N)]  # 全頂点を「未訪問」に初期化
v[0] = 0  # スタート地点を0にする
# queueを作成し部屋1（インデックスは0）を入れる
q = queue.Queue()
q.put(0)

while not q.empty():
    # queueの先頭（今いる部屋の番号）を取り出す
    x = q.get()
    # 今いる部屋と繋がっている部屋を順に探索する
    for y in graph[x]:
        # -1 でない場合は探索済みなのでスキップする
        if v[y] != -1:
            continue
        # あとで探索するためにqueueに入れておく
        q.put(y)
        v[y] = x

print("Yes")
for i in range(1, N):
    print(v[i] + 1)
l0 = input().split(' ')
N = int(l0[0])
H = int(l0[1])
L = []
i=0
while i < N:
    l1 = input().split(' ')
    l2 = [int(l1[0]), int(l1[1])]
    L.append(l2)
    i += 1
L.sort(key = lambda x:x[1])
#b_iの順に並び変え
L2 = L.copy()
L2.sort()
Amax = L2[N-1][0]
p=N-1
while p >= 0:
    if L[p][1] > Amax:
        p -= 1
    else:
        break
p += 1
Btot = 0
counter = 0
while p < N:
    Btot += L[p][1]
    p += 1
    counter += 1

rem = H - Btot
counter += rem // a
if rem % a != 0:
    counter += 1
print(counter)

### FIXED CODE ###

l0 = input().split(' ')
N = int(l0[0])
H = int(l0[1])
L = []
i=0
while i < N:
    l1 = input().split(' ')
    l2 = [int(l1[0]), int(l1[1])]
    L.append(l2)
    i += 1
L.sort(key = lambda x:x[1])
#b_iの順に並び変え
L2 = L.copy()
L2.sort()
Amax = L2[N-1][0]
p=N-1
while p >= 0:
    if L[p][1] > Amax:
        p -= 1
    else:
        break
k=N-1
Btot = 0
c=0
counter = 0
while k > p:
    H -= L[k][1]
    k -= 1
    counter += 1
    if H <= 0:
        c = counter
        break

st =  H // Amax
counter += st
if st * Amax != H:
    counter += 1
if c ==0:
    print(counter)
else:
    print(c)
from itertools import permutations

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

data = P.copy()
data.sort()

for idx, i in enumerate(list(permutations(data, N))):
    if list(i) == P:
        a = idx
    if list(i) == Q:
        b = idx

print(abs(a-b))


### FIXED CODE ###

from itertools import permutations

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

data = P.copy()
data.sort()

for idx, i in enumerate(list(permutations(data, N))):
    if list(i) == P:
        a = idx
    if list(i) == Q:
        b = idx

print(abs(a-b))
from collections import Counter
from sys import stdin

def main():
    N = int(input())
    A = map(int, input().split())

    cnt = Counter(A).most_common()
    n = N // 3
    l = len(cnt)
    if cnt[0][0] == 0 and l == 1:
        print('Yes')
        return
    if cnt[1][0] == 0 and cnt[1][1] == n and l == 2:
        print('Yes')
        return
    if N % 3:
        print('No')
        return

    if cnt[0][0] ^ cnt[1][0] == cnt[2][0] and cnt[0][1] == cnt[1][1] == n:
        print('Yes')
    else:
        print('No')

input = lambda: stdin.readline()
main()


### FIXED CODE ###

from collections import Counter
from sys import stdin

def main():
    N = int(input())
    A = map(int, input().split())

    cnt = Counter(A).most_common()
    n = N // 3
    l = len(cnt)
    if l == 1:
        if cnt[0][0] == 0:
            print('Yes')
        else:
            print('No')
        return
    if l == 2:
        if cnt[1][0] == 0 and cnt[1][1] == n:
            print('Yes')
        else:
            print('No')
        return
    if l > 3 or N % 3:
        print('No')
        return

    if cnt[0][0] ^ cnt[1][0] == cnt[2][0] and cnt[0][1] == cnt[1][1] == n:
        print('Yes')
    else:
        print('No')

input = lambda: stdin.readline()
main()
A, B = map(int,input().split()) 

def func():
    b = B*10
    for i in range(b,2*b):
        if math.floor(i*0.08) == A and math.floor(i*0.1) == B:
            return i
    return -1
    
print(func())

### FIXED CODE ###

import math

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

def func():
    b = B*10
    for i in range(b,2*b):
        if math.floor(i*0.08) == A and math.floor(i*0.1) == B:
            return i
    return -1
    
print(func())
def prime_decomposition(n):
    ret = set()

    x = n

    divisor = 2
    while x % divisor == 0:
        x //= divisor
        ret.add(divisor)

    divisor = 3
    while divisor * divisor <= n:
        while x % divisor == 0:
            x //= divisor
            ret.add(divisor)
        divisor += 2

    if x > 1:
        ret.add(x)

    return ret


def main():
    from functools import reduce
    from operator import mul

    n, k, s = map(int, input().split())

    pd = prime_decomposition(s)
    m = reduce(mul, pd) - 1  # 互いに素

    ret = [s] * k + [m] * (n - k)
    print(*ret)


if __name__ == '__main__':
    main()


### FIXED CODE ###

def prime_decomposition(n):
    ret = set()

    x = n

    divisor = 2
    while x % divisor == 0:
        x //= divisor
        ret.add(divisor)

    divisor = 3
    while divisor * divisor <= n:
        while x % divisor == 0:
            x //= divisor
            ret.add(divisor)
        divisor += 2

    if x > 1:
        ret.add(x)

    return ret


def main():
    from functools import reduce
    from operator import mul

    n, k, s = map(int, input().split())

    pd = prime_decomposition(s)
    if not pd:
        m = s + 1
    else:
        m = reduce(mul, pd) - 1  # 互いに素

    ret = [s] * k + [m] * (n - k)
    print(*ret)


if __name__ == '__main__':
    main()
x,n = map(int, input().split())
p = list(map(int, input().split()))
if n == 0:
  print(x)
elif n == 1:
  if x == p:
    print(x-1)
  else:
    print(x)
else:
  p.sort()
  m = float("inf")
  if x<p[0] or p[n-1]<x:
    print(x)
  else:
    for y in [y for y in range(p[0]-1,p[n-1]) if not y in p]:
      if abs(x-y)<m:
        m = abs(x-y)
        ans_y = y
  print(ans_y)

### FIXED CODE ###

a,b,c,d,e = map(int, input().split())
lis = [a,b,c,d,e]
for i,n in enumerate(lis):
  if n==0:
    print(i+1)
s = input()
if s == 'Sunny':
    print('Cloudy')
elif s == 'Cloudy':
    print('Rainy')
eise:
    print('Sunny')

### FIXED CODE ###

s = input()
if s == "Sunny":
    print("Cloudy")
elif s == "Cloudy":
    print("Rainy")
elif s == "Rainy":
    print("Sunny")
ans_list = []

while True:
    e = int(input())
    if e == 0:
        break
    else:
        ans = float('inf')
        for z in range(e+1):
            z3 = z ** 3
            if z3 <= e:
                for y in range(e-z3+1):
                    y2 = y ** 2
                    if y2 <= e - z3:
                        x = e - z3 - y2
                        s = x + y + z
                        if s < ans:
                            ans = s
                    else:
                        break
            else:
                break
        ans_list.append(ans)

for x in ans_list:
    print(x)


### FIXED CODE ###

while True:
    e = int(input())
    if e == 0:
        break
    z, ans = 0, float('inf')
    while z ** 3 <= e:
        r = e - z ** 3
        y = int(r ** 0.5)
        x = r - y ** 2
        ans = min(ans, x + y + z)
        z += 1
    print(ans)
N = int(input())

Alist = []
for i in range(0, N):
    Alist.append(int(input()))

for j in range(0, len(Alist)):
    if Alist[j] % 2 == 0:
        cnt = cnt + 1
if cnt % 2 == 0:
    print('second')
else:
    print('first')

### FIXED CODE ###

N = int(input())
cnt = 0
for i in range(0, N):
    if int(input()) % 2 == 1:
        cnt = cnt + 1

if cnt > 0:
    print('first')
else:
    print('second')
a = int(input())
print((1000-(N%1000))%1000)

### FIXED CODE ###

n = int(input())
ans = (1000-(n%1000))%1000
print(ans)
import sys
print( sys.stdin.split().indx("0"))

### FIXED CODE ###

print(input().split().index("0") + 1)
import math
a, b = map(int, input().split())
print((a*b)//math.gcd(a,b))


### FIXED CODE ###

a, b = map(int, input().split())
if a < b:
    a, b = b, a
A = a
B = b
while a % b != 0:
    a, b = b, a % b
print((A*B)//b)
from sys import stdin
import sys, math

a, b, h, m = [int(x) for x in stdin.readline().rstrip().split()]

x = 30*h + 0.5*m
y = 6*m

c = a**2 + b**2 - 2*a*b*abs(math.cos(math.radians(z)))
c = math.sqrt(c)

print(c)

### FIXED CODE ###

from sys import stdin
import sys, math

a, b, h, m = [int(x) for x in stdin.readline().rstrip().split()]

x = 30*h + 0.5*m
y = 6*m

z = abs(x-y)
if z > 180: z = 360 - z

c = a**2 + b**2 - 2*a*b*math.cos(math.radians(z))
c = math.sqrt(c)

print(c)
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
from itertools import accumulate
def main():
    N = int(readline())
    A = [int(i) for i in readline().split()]
    Ae = A[1::2]
    Ao = A[::2]
    x1 = (sum(Ao)-sum(Ae))//2
    table = [0]*(N+1)
    table[0] = x1
    def rec(i):
        if i == N:
            return
        table[i+1] = A[i] - table[i]
        rec(i+1)
    rec(0)
    for i in table[:N]:
        print(i*2, end=' ')
if __name__ == '__main__':
    main()


### FIXED CODE ###

#python3

def main():
    n = int(input())
    a = [int(i) for i in input().split()]
    c = 0
    for i in range(n):
        if i%2 == 0:
            c += a[i]
        else:
            c -= a[i]
    x = c//2
    xs = []
    xs.append(x)
    for i in range(2, n+1):
        z = a[i-2] - xs[i-2]
        xs.append(z)
    for i in range(n):
        xs[i] = 2*xs[i]
    for i in range(n):
        if i == n-1:
            print(xs[i])
        else:
            print(xs[i], end=' ')
main()
n = int(input())
a = list(map(int, input().split()))
ans1 = 0
ans2 = 0

diff = []
for i, index in enumerate(a,1):
    diff.append(i-index)

diff.sort()
if n % 2 == 1:
    b = diff[n // 2]
    for i in diff:
        ans1 += abs(i - b)
    print(ans1)
else:
    b1 = diff[n // 2 - 1]
    b2 = diff[n // 2]
    for i in diff:
        ans1 += abs(i -b1)
        ans2 += abs(i -b2)
    print(min(b1.b2))

### FIXED CODE ###

n = int(input())
a = list(map(int, input().split()))
diff = []
for i, index in enumerate(a,1):
    diff.append(i-index)

diff.sort()
if n % 2 == 1:
    b = diff[n // 2]
    tmp = map(lambda x: x - b, diff)
    print(sum( map(abs,tmp )))
else:
    b1 = diff[n // 2 - 1]
    b2 = diff[n // 2]
    tmp1 = map(lambda x: x - b1, diff)
    tmp2 = map(lambda x: x - b2, diff)
    ans1 = sum( map(abs,tmp1 ))
    ans2 = sum( map(abs,tmp2 ))
    print(min(ans1,ans2))
if __name__ == '__main__':
    N, Q= map(int, input().split())
    S = str(input())
    L = [list(map(int, input().split())) for _ in range(Q)]
    
    nums = [0]*(N-1)
    
    for i in range(N):
        if S[i] == 'A' and S[i+1] == 'C':
            nums[i] += 1

    for i in range(1, len(nums)):
        nums[i] = nums[i] + nums[i-1]
    
    nums = [0] + nums
    
    for l, r in L:
        print(nums[r-1] - nums[l-1])

### FIXED CODE ###

if __name__ == '__main__':
    N, Q= map(int, input().split())
    S = str(input())
    L = [list(map(int, input().split())) for _ in range(Q)]
    
    nums = [0]*(N-1)
    
    for i in range(N-1):
        if S[i] == 'A' and S[i+1] == 'C':
            nums[i] += 1

    for i in range(1, len(nums)):
        nums[i] = nums[i] + nums[i-1]
    
    nums = [0] + nums
    
    for l, r in L:
        print(nums[r-1] - nums[l-1])
import resource, sys
resource.setrlimit(resource.RLIMIT_STACK, (2**29,-1))
sys.setrecursionlimit(10**9)

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

paths = [[] for i in range(N)]
longest_paths = [-1 for i in range(N)]

for i in range(M):
    x, y = map(int, input().split())
    paths[x-1].append(y-1)

def get_longest(node):
    if longest_paths[node] != -1:
        return longest_paths[node]
    if paths[node] == []:
        longest_paths[node] = 0
        return 0
    else:
        result = max([get_longest(nd) for nd in paths[node]]) + 1
        longest_paths[node] = result
        return result

print(max([get_longest(i) for i in range(N)]))

### FIXED CODE ###

import sys
sys.setrecursionlimit(10**9)

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

paths = [[] for i in range(N)]
longest_paths = [-1 for i in range(N)]

for i in range(M):
    x, y = map(int, input().split())
    paths[x-1].append(y-1)

def get_longest(node):
    if longest_paths[node] != -1:
        return longest_paths[node]
    if paths[node] == []:
        longest_paths[node] = 0
        return 0
    else:
        result = max([get_longest(nd) for nd in paths[node]]) + 1
        longest_paths[node] = result
        return result

print(max([get_longest(i) for i in range(N)]))
n = int(input())
A = list(map(int, input().split()))
count = 0
while True:
    for i in range(n):
        if (A[i] % 2 == 1) or (A[i] == 0):
            break
        elif:
            A[j] = A[j] // 2
            s += 1
            continue
    
    break
print(count)


### FIXED CODE ###

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

def count(A, n):
    for i in range(n):
        if (A[i] % 2 == 1) or (A[i] == 0):
            return False
        A[i] = A[i] // 2
    return True

while True:
    if count(A, n):
        s += 1
    else:
        break
    
print(s)
a,b=map(int,input().split())
if a>b:
    print("GREATER")
elif a<b:
    print("LESS")
else:
    print("EQUAL")


### FIXED CODE ###

a=int(input())
b=int(input())
if a>b:
    print("GREATER")
elif a<b:
    print("LESS")
else:
    print("EQUAL")
def main():
    N, Q = map(int, input().split())
    E = [[] for i in range(N+1)]
    counter = [0] * (N+1)

    for i in range(N-1):
        a, b = map(int, input().split())
        E[a].append(b)
        E[b].append(a)

    def mktree(v, parent, E):
        children = E[v]
        #print(v, ", parent=%d"%parent, E[v])
        children.remove(parent)
        for child in children:
            mktree(child, v, E)

    for child in E[1]:
        mktree(child, 1, E)

    if 1==0:
        for child in E[1:]:
            i+=1
            print(i, child)


    for i in range(Q):
        # 頂点p を根とする部分木に含まれるカウンターにxを足す
        p, x = map(int, input().split())
        counter[p] += x

    def get(v, children, counter):
        c = counter[v]
        for child in children[v]:
            counter[child] += c
            get(child, children, counter)

    get(1, E, counter)
    print(" ".join(str(x) for x in counter[1:]))

main()






### FIXED CODE ###

def main():
    import sys
    sys.setrecursionlimit(2*10**5)
    N, Q = map(int, input().split())
    E = [[] for i in range(N+1)]
    counter = [0] * (N+1)

    for i in range(N-1):
        a, b = map(int, input().split())
        E[a].append(b)
        E[b].append(a)

    for i in range(Q):
        # 頂点p を根とする部分木に含まれるカウンターにxを足す
        p, x = map(int, input().split())
        counter[p] += x

    queue = []

    parent = [1]
    def mktree(v, parent, E):
        children = E[v]
        children.remove(parent)
        for child in children:
            mktree(child, v, E)

    while parent:
        p = parent.pop()
        for child in E[p]:
            E[child].remove(p)
            parent.append(child)

    def get(v, children, counter):
        c = counter[v]
        for child in children[v]:
            counter[child] += c
            get(child, children, counter)

    parent = [1]
    while parent:
        p = parent.pop()
        c = counter[p]
        for child in E[p]:
            counter[child] += c
            parent.append(child)

    print(" ".join(str(x) for x in counter[1:]))

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

ans = []
for i in range(1, N+1, 1):
    ans.append(A.index(i)+1)
    
for j in range(N):
    print(ans[j], end=" ")

### FIXED CODE ###

N = int(input())
odd = 0
for i in range(0, N+1, 1):
    if i % 2 == 0:
        continue
    elif i % 2 == 1:
        odd += 1
print(float(odd/N))
import numpy as np
import math

def main():
    a, b = map(int, input().split())

    # print(a/0.08)

    a_ans = np.array([i for i in range(math.ceil(a/0.08), int((a+1)/0.08))])
    b_ans = np.array([j for j in range(math.ceil(b/0.1), int((b+1)/0.1))])

    # print(a_ans)
    # print(b_ans)
    #
    # print(a_ans * 0.08)
    # print(b_ans * 0.1)

    ans = set(a_ans) & set(b_ans)

    # print(ans)

    if ans == set():
        print(-1)
    else:
        print(min(ans))

if __name__ == '__main__':
    main()

### FIXED CODE ###

import numpy as np
import math

def main():
    a, b = map(int, input().split())

    # print(a/0.08)

    a_ans = np.array([i for i in range(math.ceil(a/0.08), int((a+1)/0.08))])
    b_ans = np.array([j for j in range(math.ceil(b/0.1), int((b+1)/0.1))])

    # print(a_ans)
    # print(b_ans)
    #
    # print(a_ans * 0.08)
    # print(b_ans * 0.1)

    ans = set(a_ans) & set(b_ans)

    # print(ans)

    if ans == set():
        print(-1)
    else:
        print(min(ans))

if __name__ == '__main__':
    main()
A,B,C = [int(x) for x in input().split()]
K=input()

while(A>B):
  K-=1
  if K==0:
    print("No")
    exit()
  B=B*2

while(B>C):
  C=C*2
  if K==1:
    break
  K-=1
  if K==0:
    print("No")
    exit()

print("Yes")


### FIXED CODE ###

A,B,C = [int(x) for x in input().split()]
K=int(input())
 
while(A>=B and K>0):
  B=B*2
  K-=1
 
while(B>=C and K>0):
  C=C*2
  K-=1

if B>A and C>B:
  print("Yes")
else:
  print("No")
print("".join(input().split()[::-1])

### FIXED CODE ###

print("".join(input().split()[::-1]))