Harryxun/stf_run huggingface dataset:
n = int(raw_input())                                                                                                                                                                                         
data = [0] * n                                                                                                                                                                                           
                                                                                                                                                                                                             
for a in range(n):                                                                                                                                                                                       
　t = int(raw_input())                                                                                                                                                                                     
  data[t] += 1                                                                                                                                                                                         
                                                                                                                                                                                                             for a in range(n):                                                                                                                                                                                       
　if data[a] == 0:                                                                                                                                                                                     
  　print '-'                                                                                                                                                                                           　else:                                                                                                                                                                                                
　　for t in range(data[a]):                                                                                                                                                                         
　　　print '*',                                                                                                                                                                           
　　print                    

### FIXED CODE ###

#!/usr/bin/env python3

d_init = [0] * 10
while True:
    data = d_init[:]
    n = int(input())
    if n == 0:
        break

    for _ in range(n):
        in_data = int(input())
        data[in_data] += 1

    for d in data:
        if d == 0:
            print("-")
        else:
            print("*" * d)
import sys
if __name__ == "__main__":
    N = int(input())
    P = []
    Q = [0]*(N+1)
    for i in range(1, N+1):
        p = int(input())
        Q[p] = i

    # 1 4 5 2 3 -> 4 5を移動
    # 1 4 5 3 2 -> 3 4 5 を移動
    # 5 2 1 3 4 -> 1 5 を移動
    cur = 1
    max_cur = 1
    for i in range(1, N):
        if Q[i] < Q[i+1]:
            cur += 1
            max = max(cur, max_cur)
        else:
            cur = 1
    print(N - max_cur)

### FIXED CODE ###

import sys
if __name__ == "__main__":
    N = int(input())
    P = []
    Q = [0]*(N+1)
    for i in range(1, N+1):
        p = int(input())
        Q[p] = i

    # 1 4 5 2 3 -> 4 5を移動
    # 1 4 5 3 2 -> 3 4 5 を移動
    # 5 2 1 3 4 -> 1 5 を移動
    cur = 1
    max_cur = 1
    for i in range(1, N):
        if Q[i] < Q[i+1]:
            cur += 1
            max_cur = max(cur, max_cur)
        else:
            cur = 1
    print(N - max_cur)
N, M = map(int, input().split())
A = list(map(int, input().split()))
BC = [list(map(int, input().split())) for i in range(M)]
BC = sorted(BC, key=lambda x: x[1])
A.sort()
i = 0
for b, c in BC[::-1]:
    if i == N:
        break
    for _ in range(b):
        if c > A[i]:
            A[i] = c
            i += 1
        else:
            break

print(sum(A))


### FIXED CODE ###

N, M = map(int, input().split())
A = list(map(int, input().split()))
BC = [list(map(int, input().split())) for i in range(M)]
BC = sorted(BC, key=lambda x: x[1])
A.sort()
i = 0
for b, c in BC[::-1]:
    for _ in range(b):
        if i == N:
            break
        if c > A[i]:
            A[i] = c
            i += 1
        else:
            break

print(sum(A))
n, q = map(int, input().split())
ab_lst = [list(map(int, input().split())) for _ in range(n-1)]
px_lst = [list(map(int, input().split())) for _ in range(q)]

res = [0] * (n+1)
neighbor = [[] for _ in range(n+1)]
for edge in ab_lst:
    neighbor[edge[0]].append(edge[1])

def counter_add(root, v):
    res[root] += v
    if neighbor[root] != []:
        for i in neighbor[root]:
            counter_add(i, v)

for px in px_lst:
    counter_add(px[0], px[1])
print(res)

### FIXED CODE ###

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

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

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

res = [0] * (n+1)
queue = [(1, root_value[1])]
while len(queue) > 0:
    pair = queue.pop()
    res[pair[0]] += pair[1]
    if neighbor[pair[0]] != []:
        for i in neighbor[pair[0]]:
            queue.append((i, pair[1] + root_value[i]))
    
for i in res[1:]:
    print(i, end=" ")
s = raw_input()
if(s[-1] == 's'):
    s += 'es'
else:
    s += 's'
print(s)


### FIXED CODE ###

s = input()
if(s[-1] == 's'):
    s += 'es'
else:
    s += 's'
print(s)
N = input()

print(N.count(1))

### FIXED CODE ###

N = input()
 
print(N.count("1"))
x = input().split()
A, B = [int(num) for num in x]
K = (A+B)/2
if int(K) = K:
  print(K)
else:
  print("IMPOSSIBLE")

### FIXED CODE ###

x = input().split()
A, B = [int(num) for num in x]
K = (A+B)/2
if int(K) == K:
  print(int(K))
else:
  print("IMPOSSIBLE")
import sys
from functools import reduce
from math import gcd

POSSIBLE = "POSSIBLE"
IMPOSSIBLE = "IMPOSSIBLE"
n, k = map(int, input().split())
a = list(map(int, input().split()))

# max(a) < k → だめ
# N == 1 ぴったじゃなきゃだめ
# N > 1
## 互いに素な数が含まれている → ○
## 含まれてないが、kがその倍数 → ○
if max(a) < k:
    print(IMPOSSIBLE)
    exit()
if n == 1:
    if k == a[0]:
        print(POSSIBLE)
    else:
        print(IMPOSSIBLE)
else:
    g = reduce(lambda a, b: gcd(a, b), a)
    if g == 1:
        print(POSSIBLE)
    else:
        if k % g == 0:
            print(POSSIBLE)
        else:
            print(IMPOSSIBLE)



### FIXED CODE ###

from functools import reduce
from fractions import gcd

POSSIBLE = "POSSIBLE"
IMPOSSIBLE = "IMPOSSIBLE"
n, k = map(int, input().split())
a = list(map(int, input().split()))

# max(a) < k → だめ
# N == 1 ぴったじゃなきゃだめ
# N > 1
## 互いに素な数が含まれている → ○
## 含まれてないが、kがその倍数 → ○
if max(a) < k:
    print(IMPOSSIBLE)
    exit()
if n == 1:
    if k == a[0]:
        print(POSSIBLE)
    else:
        print(IMPOSSIBLE)
else:
    g = reduce(lambda a, b: gcd(a, b), a)
    if g == 1:
        print(POSSIBLE)
    else:
        if k % g == 0:
            print(POSSIBLE)
        else:
            print(IMPOSSIBLE)
INFTY = 100000000
n = int( raw_input() )
graph = {}
for i in range(n):
  In = map( int , raw_input().split('') )
  u = In[0]
  k = In[1]
  graph[u] = {}
  for j in range(k):
    v = In[2+j*2]
    c = In[2+j*2+1]
    graph[u][v] = c
 
da = {}
visited = {}
for i in range(n):
  da[i] = INFTY
  visited[i] = False
s = 0
da[s] = 0
visited[s] = True
 
while True:
  for i in range(n):
    if not visited[i] and i in graph[s] and da[i] > da[s] + graph[s][i]:
      da[i] = da[s] + graph[s][i]
  cost = INFTY
  node = -1
  for i in range(n):
    if not visited[i] and da[i] < cost:
      cost = da[i]
      node = i
  if cost == INFTY:
    break
  visited[node] = True
  s = node
  
for i in range(n):
  print i,da[i]

### FIXED CODE ###

INFTY = 100000000
n = int( raw_input() )
graph = {}
for i in range(n):
  In = map( int , raw_input().split(' ') )
  u = In[0]
  k = In[1]
  graph[u] = {}
  for j in range(k):
    v = In[2+j*2]
    c = In[2+j*2+1]
    graph[u][v] = c
 
da = {}
visited = {}
for i in range(n):
  da[i] = INFTY
  visited[i] = False
s = 0
da[s] = 0
visited[s] = True
 
while True:
  for i in range(n):
    if not visited[i] and i in graph[s] and da[i] > da[s] + graph[s][i]:
      da[i] = da[s] + graph[s][i]
  cost = INFTY
  node = -1
  for i in range(n):
    if not visited[i] and da[i] < cost:
      cost = da[i]
      node = i
  if cost == INFTY: 
    break
  visited[node] = True
  s = node
  
for i in range(n):
  print i,da[i]
import math
a, b, c, d = map(int, input().split())

if math.ceil(a/d) >= math.ceil(c/b):
    print("Yes")
else:
    print("No")

### FIXED CODE ###

a, b = map(int, input().split())
if a>b:
    print("safe")
else:
    print("unsafe")
X=int(input())
i=1
sum1=1
while sum<X:
  i+=1
  sum1=sum1+i
print(i)


### FIXED CODE ###

X=int(input())
i=1
sum1=1
while sum1<X:
  i+=1
  sum1=sum1+i
print(i)
# # Make IO faster
# import sys
# input = sys.stdin.readline

# # get single (or) multiple str
# X = input()

# # get single int
# N = int(input())
# # get multiple int (e.g., 2)
# X, Y = map(int, input().split())
# # get multiple int (e.g., 2) for N lines
# XY = [list(map(int, input().split())) for _ in range(N)]

# from IPython import embed; embed(); exit();

# 全部入り
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
import numpy as np
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

A, B, C, D = MAP()
print(min(A, B) + min(C, D))


### FIXED CODE ###

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

print(min(a,b)+min(c,d))
N = input()

if n.isupper() == true:
  print("A")
else:
  print("a")

### FIXED CODE ###

if input().isupper():
  print('A')
else:
  print('a')
A,B,M=map(int,input().split())
a=list(map(int,input().split()))
b=list(map(int,input().split()))
D=[]
for i in range(M):
    D.append(list(map(int,input().split())))
    
S=min(a)+min(b)
P=[]
for i in range(M):
    P.append(a[D[i][0]-1]+b[D[i][0]-1]-D[i][2])
P.append(S)
print(min(P))

### FIXED CODE ###

A,B,M=map(int,input().split())
a=list(map(int,input().split()))
b=list(map(int,input().split()))
D=[]
for i in range(M):
    D.append(list(map(int,input().split())))
    
S=min(a)+min(b)
P=[]
for i in range(M):
    P.append(a[D[i][0]-1]+b[D[i][1]-1]-D[i][2])
P.append(S)
print(min(P))
S = input()

S = S.replace("dream",'"")
S = S.replace("dreamer","")
S = S.replace("erase","")
S = S.replace("eraser","")

if len(S) == 0:
    ans = "YES"
else:
    ans = "NO"

print(ans)


### FIXED CODE ###

S = input()
S = S.replace('eraser', '')
S = S.replace('erase', '')
S = S.replace('dreamer', '')
S = S.replace('dream', '')
if len(S) == 0:
    print('YES')
else:
    print('NO')
#DECLARE K AND S INPUT
K = int(input())
S = input()

str = S

#if same, no change
#IF bigger plus ...

if lens(S) > K:
       print(str[0:K]+"...")

else:
       print(str)

### FIXED CODE ###

# Take both input K & S, then compare the length of S with K and assign it to length
# If the length is <= K print all
# And if length is >K print some of the character

K = int(input())
S = input()

x = 0

length = len(S)

if length <= K:
    print(S)
else:
    while x < K:
        print(S[x], end=(""))
        x += 1
    print("...")
bingo = []
bingo[0] , bingo[1] , bingo[2] = map(int, input().split())
bingo[3] , bingo[4], bingo[5] = map(int, input().split())
bingo[6], bingo[7], bingo[8] = map(int, input().split())
n = int(input())
ls = []
counter = 0
for i in range(n):
  ls[i] = int(input())

for i in range(len(bingo)):
  for j in range(len(ls)):
    if ls[j] == bingo[i]:
      bingo[i] = 0
      break
for i in range(len(bingo)):
  if i == 0:
    if bingo[i] + bingo[i+1] + bingo[i+2] == 0:
      counter += 1
      break
    elif bingo[i] + bingo[i+3] + bingo[i+6] == 0:
      counter += 1
      break
    elif bingo[i] + bingo[i+4] + bingo[i+8] == 0:
      counter += 1
      break
  elif i == 1:
    if bingo[i] + bingo[i+3] + bingo[i+6] == 0:
      counter += 1
      break
  elif i == 2:
    if bingo[i] + bingo[i+3] + bingo[i+6] == 0:
      counter += 1
      break
    elif bingo[i] + bingo[i+2] + bingo[i+4] == 0:
      counter += 1
      break
  elif i == 3:
    if bingo[i] + bingo[i+1] + bingo[i+2] == 0:
      counter += 1
      break
  elif i == 6:
    if bingo[i] + bingo[i+1] + bingo[i+2] == 0:
      counter += 1
      break
if counter > 0:
  print("Yes")
else: 
  print("No")
  

### FIXED CODE ###

bingo = [1,1,1,1,1,1,1,1,1]
bingo[0] , bingo[1] , bingo[2] = map(int, input().split())
bingo[3] , bingo[4], bingo[5] = map(int, input().split())
bingo[6], bingo[7], bingo[8] = map(int, input().split())
n = int(input())
ls = []
counter = 0
for i in range(n):
  ls.append(int(input()))
 
for i in range(len(bingo)):
  for j in range(len(ls)):
    if ls[j] == bingo[i]:
      bingo[i] = 0
      break
for i in range(len(bingo)):
  if i == 0:
    if bingo[i] + bingo[i+1] + bingo[i+2] == 0:
      counter += 1
      break
    elif bingo[i] + bingo[i+3] + bingo[i+6] == 0:
      counter += 1
      break
    elif bingo[i] + bingo[i+4] + bingo[i+8] == 0:
      counter += 1
      break
  elif i == 1:
    if bingo[i] + bingo[i+3] + bingo[i+6] == 0:
      counter += 1
      break
  elif i == 2:
    if bingo[i] + bingo[i+3] + bingo[i+6] == 0:
      counter += 1
      break
    elif bingo[i] + bingo[i+2] + bingo[i+4] == 0:
      counter += 1
      break
  elif i == 3:
    if bingo[i] + bingo[i+1] + bingo[i+2] == 0:
      counter += 1
      break
  elif i == 6:
    if bingo[i] + bingo[i+1] + bingo[i+2] == 0:
      counter += 1
      break
if counter > 0:
  print("Yes")
else: 
  print("No")
X = map(int, input().split())
for K in range(1,100):
  print(X - K)
for K in range(1,100):
  print(X + K)

### FIXED CODE ###

K,X = map(int, input().split())
for i in range(X-K+1,X+K):
  if i <= X+K-1:
    print(i, end=" ")
  else:
    print(i)
n,m,l = map(int,raw_input().split())
a = [map(int,raw_input().split()) for _ in range(n)]
b = [map(int,raw_input().split()) for _ in range(m)]
c = [[0 for i in range(n)] for j in range(l)]

for i in range(n):
    for j in range(l):
        s = 0
        for k in range(m):
            s += a[i][k] * b[k][j]
        c[i][j] = s

for i in range(n):
    print ' '.join(map(str,c[i]))

### FIXED CODE ###

n,m,l = map(int,raw_input().split())
a = [map(int,raw_input().split()) for _ in range(n)]
b = [map(int,raw_input().split()) for _ in range(m)]
c = [[0 for i in range(l)] for j in range(n)]

for i in range(n):
    for j in range(l):
        s = 0
        for k in range(m):
            s += a[i][k] * b[k][j]
        c[i][j] = s

for i in range(n):
    print ' '.join(map(str,c[i]))
s1,s2=input().split(",")
s1=s1.lower()
s2=s2.lower()
flag=0
if(len(s1)>len(s2)):
   a=len(s2)
else:
    a=len(s1)

for i in range(0,a):
    if(s1[i]==s2[i]):
        flag=flag+1
    elif(s1[i]>s2[i]):
            print('>')
            break;
    elif(s1[i]<s2[i]):
            print('<')
            break;
if(flag==a):
    if(len(s1)>len(s2)):
        print(">")

    elif(len(s1)<len(s2)):
        print("<")
    else:
            print("=")
        
    

### FIXED CODE ###

s1,s2=input().split(" ")
s1=s1.lower()
s2=s2.lower()
flag=0
if(len(s1)>len(s2)):
   a=len(s2)
else:
    a=len(s1)

for i in range(0,a):
    if(s1[i]==s2[i]):
        flag=flag+1
    elif(s1[i]>s2[i]):
            print('>')
            break;
    elif(s1[i]<s2[i]):
            print('<')
            break;
if(flag==a):
    if(len(s1)>len(s2)):
        print(">")

    elif(len(s1)<len(s2)):
        print("<")
    else:
            print("=")
#!/usr/bin/python3

from itertools import product
from collections import Counter

def main():
  n = int(input())
  x = []
  y = []

  if n == 1:
    print(1)
    return

  for i in range(n):
    x_tmp, y_tmp = map(int, input().split(' '))
    x.append(x_tmp)
    y.append(y_tmp)

  cnt = Counter()

  for i, j in product(range(n), 2):
    dist = (x[i] - x[j], y[i]- y[j])
    cnt[dist] += 1

  dist, c = cnt.most_common(1)[0]
  print(n - c)

if __name__ == '__main__':
  main()

### FIXED CODE ###

#!/usr/bin/python3

from itertools import permutations
from collections import Counter

def main():
  n = int(input())
  x = []
  y = []

  if n == 1:
    print(1)
    return

  for i in range(n):
    x_tmp, y_tmp = map(int, input().split(' '))
    x.append(x_tmp)
    y.append(y_tmp)

  cnt = Counter()

  for i, j in permutations(range(n), 2):
    dist = (x[i] - x[j], y[i]- y[j])
    cnt[dist] += 1

  dist, c = cnt.most_common(1)[0]
  print(n - c)

if __name__ == '__main__':
  main()
s = input()

if s == 'SUN':
  return 7
elif s == 'MON':
  return 6
elif s == 'TUE':
  return 5
elif s == 'WED':
  return 4
elif s == 'THU':
  return 3
elif s == 'FRI':
  return 2
else s == 'SAT':
  return 1

### FIXED CODE ###

s = input()
if s == 'SUN':
  print(7)
elif s == 'MON':
  print(6)
elif s == 'TUE':
  print(5)
elif s == 'WED':
  print(4)
elif s == 'THU':
 print(3)
elif s == 'FRI':
  print(2)
else:
  print(1)
import sys

charas = 'abcdefghijklmnopqrstuvwxyz'

for line in sys.stdin:
    data.appen(line)
for chara in chara:
    for row in data:
        cnt = row.count(chara)
        cnt += row.count(chara.upper())
    print('{} : {}'.format(chara, cnt))

### FIXED CODE ###

# coding: utf-8
alphabet = 'abcdefghijklmnopqrstuvwxyz'
S = ''
while True:
    try:
        n = input()
        S += n
    except EOFError:
        break
ans_dict = {}
for char in alphabet:
    ans_dict[char] = S.count(char)
    ans_dict[char] += S.count(char.upper())
for k, v in sorted(ans_dict.items(), key=lambda x: x[0]):
    print('{} : {}'.format(k, v))
i = 0
while 1:
   x = raw_input()
   i += 1
   if x == 0: 
     break
   print "Case %s: %s" % (i,x)

### FIXED CODE ###

i = 0
while 1:
   x = raw_input()
   i += 1
   if x == '0': 
     break
   print "Case %s: %s" % (i,x)
n,x=map(int,input().split())
x_list=list(map(int,input().split()))
d_list=[]
for i in x_list:
    d_list.append(abs(x-i))
import fractions
answer=fractions.gcd(d_list[0],d_list[1])
for i in range(2,n):
    answer=fractions.gcd(answer,d_list[i])
print(answer)


### FIXED CODE ###

n,x=map(int,input().split())
x_list=list(map(int,input().split()))
d_list=[]
for i in x_list:
    d_list.append(abs(x-i))
import fractions
if n==1:
    answer=d_list[0]
else:
    answer=fractions.gcd(d_list[0],d_list[1])
    for i in range(2,n):
        answer=fractions.gcd(answer,d_list[i])
print(answer)
a, b, c, k = map(int, input().split())

if (a + b >= k or a == k) or (a == 0 and c == 0):
    print(a)
else:
    print(a + ((a+b) - k))


### FIXED CODE ###

s = input()
t = input()

print("Yes" if s == t[:-1] else "No")
K = int(input())

S = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
print(S[K + 1])

### FIXED CODE ###

K = int(input())

S = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
print(S[K - 1])
n=int(input())
s=input()
t=[]
for i in range(n):
  t.append(s[i])
p=0
for i in range(10):
  pi=t.find(str(i))
  if pi==-1:
    continue
  for j in range(10):
    pj=t.find(str(j),pi)
    if pj==-1:
      continue
    for k in range(10):
      pk=t.find(str(k),pj)
      if pk==-1:
        continue
      p=p+1
print(p)

### FIXED CODE ###

n=int(input())
s=input()
p=0
for i in range(10):
  pi=s.find(str(i))
  if pi==-1:
    continue
  for j in range(10):
    pj=s.find(str(j),pi+1)
    if pj==-1:
      continue
    for k in range(10):
      pk=s.find(str(k),pj+1)
      if pk==-1:
        continue
      p=p+1
print(p)
H,W,K=map(int,input().split())
c=[list(input()) for i in range(H)]
b=0
for i in range(H):
  b+=c[i].count('#')
if b==K:
  print(1)
  exit()
  
else:
  a=K-b
  count=0
  hc=[]
  wc=[]
  for i in range(2 ** H):
    h=['0']*H 
    for j in range(H):
        if ((i >> j) & 1):
            h[H- 1 - j] = '1'
    hc.append(h)
  for i in range(2 ** W):
    w=['0']*W
    for j in range(W):
        if ((i >> j) & 1):
            w[W- 1 - j] = '1'
    wc.append(w)
  
  for k in range(len(hc)):
    for l in range(len(wc)):
      c1=list(c)
      for m in range(H):
        if hc[k][m]=='0':
          c1[m]='.'
        for n in range(W):
          if wc[l][n]=='0' and c1[m][n]=='#':
                c1[m][n]=c1[m][n].replace('#','.')
      for i in range(H):
        b+=c1[i].count('#')
        print(c1)
      if b==a:
        count+=1
        
print(count)
    
            
  

### FIXED CODE ###

import collections

N=int(input())
A=list(map(int, input().split()))
Q=int(input())
countA=collections.Counter(A)
ans=sum(A)

for i in range(Q):
    B,C=map(int, input().split())
    b=countA[B]
    ans=ans+(C-B)*b
    print(ans)
    countA[B]=0
    countA[C]+=b
N = int(input())
A = list(map(int, input().split()))
B = list(map(int, input().split()))

num = 0
diff = 0
for i in range(N):
    if A[i] != B[i]:
        num += 1
        
    diff += A[i] - B[i]
    
if diff%num == 0 and diff >= 0:
    print('Yes')
else:
    print('No')
        



### FIXED CODE ###

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

a_b = 0
b_a = 0
for i in range(N):
    if A[i] > B[i]:
        a_b += A[i] - B[i]
        
    else:
        b_a += (B[i] - A[i]) // 2

if a_b <= b_a:
    print('Yes')
else:
    print('No')
a, b = input().strip().split()
print(max([a+b,a-b,a*b]))

### FIXED CODE ###

a, b = input().strip().split()
a, b = [int(a), int(b)]
print(max([a+b,a-b,a*b]))
N=int(input())
X=int(input())
T=int(input())
print((N//X+1)*T)


### FIXED CODE ###

n,x,t=map(int,input().split())
if n%x==0:
  print(n//x*t)
else:
  print((n//x+1)*t)
a,b=map(int,input().split())
def yaku(n):
  l=[]
  m=n
  for i in range(1,int((n)**(1/2))+1):
    if m%i==0:
      l.append(i)
      if m//i!=i:
        l.append(m//i)
  return l
l=yaku(a)
cd=[]
for i in l:
  if a%i==0:
    cd.append(i)
count=0
length=len(cd)
def gcd(n,m):
  a=max(n,m)
  b=min(n,m)
  while b!=0:
    a,b=b,a%b
  return a
for i in range(length-1):
  for j in range(i+1,length):
    if gcd(cd[i],cd[j])==1:
      count+=1
print(count)


### FIXED CODE ###

n=int(input())
if n%2==0:
  print(0.5)
else:
  print((n//2+1)/n)
a = input()
b = list(map(int, a.split()))
b.sort()
print(b[0]+" " + b[1]+ " " +b[2])


### FIXED CODE ###

a = input()
b = list(map(int, a.split()))
b.sort()
print(str(b[0])+" " + str(b[1])+ " " +str(b[2]))