Harryxun/stf_run huggingface dataset:
x = int(input())

my_dict = dict()

for i in range(10 ** 5):
    my_dict[i**5] = i

for i in range(-10 ** 5, 10 ** 5):
    target = x + (i ** 5)
    if (- target) in my_dict:
        print(-my_dict[target], i)
        exit()
    elif target in my_dict:
        print(my_dict[target], i)
        exit()


### FIXED CODE ###

x = int(input())

my_dict = dict()

for i in range(1000):
    my_dict[i**5] = i

for i in range(-1000, 1000):
    target = x + (i ** 5)
    if (- target) in my_dict:
        print(-my_dict[-target], i)
        exit()
    elif target in my_dict:
        print(my_dict[target], i)
        exit()
import sys
import time
#from collections import deque, Counter, defaultdict
#from fractions import gcd
import bisect
#import heapq
import math
input = sys.stdin.readline
sys.setrecursionlimit(10**8)
inf = 10**18
MOD = 1000000007
ri = lambda : int(input())
rs = lambda : input().strip()
rl = lambda : list(map(int, input().split()))
n = rl()
a=rl()
a.sort()
b=[0]*(2*10**5+1)
def make_divisors(n):
    lower_divisors , upper_divisors = [], []
    i = 1
    while i*i <= n:
        if n % i == 0:
            lower_divisors.append(i)
            if i != n // i:
                upper_divisors.append(n//i)
        i += 1
    return lower_divisors + upper_divisors[::-1]

for i in a:
    f=True
    if b[i]==-1:
        b[i]=1
        continue
    for j in make_divisors(i):
        if b[j]==-1:
            f=False
            break
    if f:
        b[i]=-1
cnt=0
for i in b:
    if i==-1:
        cnt+=1
print(cnt)

### FIXED CODE ###

import sys
import time
#from collections import deque, Counter, defaultdict
#from fractions import gcd
import bisect
#import heapq
import math
start=time.time()
input = sys.stdin.readline
sys.setrecursionlimit(10**8)
inf = 10**18
MOD = 1000000007
ri = lambda : int(input())
rs = lambda : input().strip()
rl = lambda : list(map(int, input().split()))
n = rl()
a=rl()
a.sort()
b=[0]*2*10**6
for i in a:
    if b[i]==0:
        b[i]=-1
        for j in range(2,10**6):
            if i*j>10**6:
                break
            b[i*j]+=1
        continue
    
    if b[i]==-1:
        b[i]=1
cnt = 0
for i in a:
    if b[i]==-1:
        cnt+=1
print(cnt)
s=list(input())
while len(s) != 0:
  s.pop()
  if len(s)%2==0 and s[:len(s)//2]==s[len(s)//2:]:
    print(len(s)
    exit()

### FIXED CODE ###

s=list(input())
while len(s) != 0:
  s.pop()
  if len(s)%2==0 and s[:len(s)//2]==s[len(s)//2:]:
    print(len(s))
    exit()
N = int(input())
cnt = 0
L = list(map(int,input()..split()))
for i in range(N-2):
  if (L[i] > L[i+1] < L[i+2]) or (L[i] < L[i+1] > L[i+2]):
    cnt += 1
print(cnt)

### FIXED CODE ###

N = int(input())
cnt = 0
tmp = ''
M = list(map(int,input().split()))
L = []
for x in M:
    if x == tmp:
        pass
    else:
        L.append(x)
    tmp = x
    

    
while True:
    try: 
        if L[0] <L[1]>L[2] or L[0] > L[1] <L[2]:
            a0=L.pop(0)
            a1=L.pop(0)
            cnt += 1
        else:
            L.pop(0)
    except:
        break
#    print(L)
print(1+cnt)
# import sys
# sys.setrecursionlimit(2147483647)

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


vertice = [-1 for _ in range(n)]
stack = [(0, 0)]

while stack:
    parent, vertex = stack.pop()
    vertice[vertex] = vertice[parent] * (-1)
    for next in edges[vertex]:
        if next != parent:
            stack.append((vertex, next))

# vertice = [0 for _ in range(n)]
#
#
# def dfs(v, color_i):
#     vertice[v] = color_i
#     for i in edges[v]:
#         if vertice[i] == 0:
#             dfs(i, color_i*(-1))
#
# dfs(0, 1)

ans = []
if vertice.count(1) <= n // 3:
    not3 = [i for i in range(1, n+1) if i % 3 != 0]
    num3 = [i for i in range(1, n+1) if i % 3 == 0]
    for v in vertice:
        if v == 1:
            if num3:
                ans.append(str(num3.pop()))
            elif not3:
                ans.append(str(not3.pop()))
        else:
            ans.append(str(not3.pop()))
elif vertice.count(-1) <= n // 3:
    not3 = [i for i in range(1, n+1) if i % 3 != 0]
    num3 = [i for i in range(1, n+1) if i % 3 == 0]
    for v in vertice:
        if v == -1:
            if num3:
                ans.append(str(num3.pop()))
            elif not3:
                ans.append(str(not3.pop()))
        else:
            ans.append(str(not3.pop()))
else:
    num1 = [i for i in range(1, n+1) if i % 3 == 1]
    num2 = [i for i in range(1, n+1) if i % 3 == 2]
    num3 = [i for i in range(1, n+1) if i % 3 == 0]
    for v in vertice:
        if v == 1:
            if num1:
                ans.append(str(num1.pop()))
            else:
                ans.append(str(num3.pop()))
        else:
            if num2:
                ans.append(str(num2.pop()))
            else:
                ans.append(str(num3.pop()))

print(" ".join(ans))


### FIXED CODE ###

n = int(input())
edge = [[] for _ in range(n)]
for _ in range(n-1):
  a, b = map(int, input().split())
  edge[a-1].append(b-1)
  edge[b-1].append(a-1)
 
group = [False] * n
parent = list(range(n))
stack = [0]
while stack:
  v = stack.pop()
  while edge[v]:
    u = edge[v].pop()
    if parent[v] != u:
      group[u] = not group[v]
      parent[u] = v
      stack.append(u)
 
three = 3
p = [0] * n
if group.count(False) <= n // 3:
  other = 1
  for i in range(n):
    if group[i] and other <= n:
      p[i] = other
      other += other % 3
    else:
      p[i] = three
      three += 3
elif group.count(True) <= n // 3:
  other = 1
  for i in range(n):
    if not group[i] and other <= n:
      p[i] = other
      other += other % 3
    else:
      p[i] = three
      three += 3
else:
  one, two = 1, 2
  for i in range(n):
    if group[i] and one <= n:
      p[i] = one
      one += 3
    elif not group[i] and two <= n:
      p[i] = two
      two += 3
    else:
      p[i] = three
      three += 3
print(' '.join(map(str, p)))
N, M = map(int, input().split())
AB = [list(map(int, input().split())) for i in range(M)]

connect_list = [set() for _ in range(N)]
ranking = [set() for _ in range(N)]
ranked_set = set()
full_set = {i for i in range(1, N+1)}


def do_ranking(set, rank):
    global connect_list, ranking, ranked_set, full_set
    if ranked_set == full_set:
        return 0
    for j in list(set):
        for i in list(connect_list[j-1]):
            if i not in ranked_set:
                ranking[rank].add(i)
                ranked_set.add(i)
    do_ranking(ranking[rank], rank+1)



for A, B in AB:
    connect_list[A-1].add(B)
    connect_list[B-1].add(A)
ranking[0] = connect_list[0]
ranked_set = ranked_set | ranking[0]
ranked_set.add(1)
do_ranking(ranking[0], 1)

root_list = [0]*N
root_list[0] = "Yes"
count = 0
no_flag = False
for i in range(1, N):
    flag = True
    j = 0
    while flag:
        if len(ranking[j]) == 0:
            no_flag = True
            break
        seki = connect_list[i] & ranking[j]
        if 1 in connect_list[i]:
            root_list[i] = 1
            flag = False
        elif len(seki) != 0:
            print(seki)
            root_list[i] = list(seki)[0]
            flag = False
        else:
            j += 1
    if no_flag:
        print("No")
        break
if no_flag == False:
    for i in root_list:
        print(i)


### FIXED CODE ###

N, M = map(int, input().split())
connect_list = [set() for _ in range(N)]    #繋がっているリスト
for _ in range(M):
    A, B = map(int, input().split())
    connect_list[A-1].add(B)
    connect_list[B-1].add(A)

root_list = [0]*N
root_list[0] = "Yes"

for i in list(connect_list[0]):
    root_list[i-1] = 1
now_set = connect_list[0]
while len(now_set) != 0:
    for j in list(now_set):
        for i in list(connect_list[j-1]):
            if root_list[i-1] == 0:
                root_list[i-1] = j
                now_set.add(i)
        now_set.remove(j)

for i in root_list:
    print(i)
N = int(input())
x = [0] * N
u = [0] * N

ans = []

btc_1 = 380000.0


for i in range(N):
    x[i],u[i] = map(int, input().split())

        if u[i] == "JPY":
            ans.append(x[i])
    　　else:
        yen = ((x[i])*(btc_1))
        ans.append(yen)



print(sum(ans))

### FIXED CODE ###

N=int(input())
ans=0
for i in range(N):
    x,u=map(str,input().split())
    x=float(x)
    if u=="JPY":
        ans+=x
    else:
        ans+=380000.0*x
print(ans)
s=set(list(input()))

if les(s)==1:
    print("Yes")
else:
    print("No")

### FIXED CODE ###

s=set(list(input()))

if len(s)==1:
    print("No")
else:
    print("Yes")
sx,sy,gx,gy=map(int,input().split())
n=int(input())
g = [[] for i in range(n+2)]
data=[(sx,sy,0)]
for i in range(n):
    data.append(tuple(map(int,input().split())))
data.append((gx,gy,0))
for i in range(n+2):
    for j in range(i+1,n+2):
        tmp=(data[i][0]-data[j][0])**2+(data[i][1]-data[j][1])**2)**0.5-data[i][2]-data[j][2]
        if tmp<0:
            tmp=0
        g[i].append((tmp,j))
        g[j].append((tmp,i))

def dijkstra(g,st,ed):
    from heapq import heappush, heappop, heapify
    dist=[2828427127 for i in range(len(g))]
    dist[st]=0
    que=[]
    heappush(que,(0,st))
    while que:
        c,v=heappop(que)
        if dist[v]<c:
            continue
        for i in range(len(g[v])):
            tmp=g[v][i][0]+c
            if tmp<dist[g[v][i][1]]:
                dist[g[v][i][1]]=tmp
                heappush(que,(tmp,g[v][i][1]))
    return dist[ed]

print(dijkstra(g,0,n+1))

### FIXED CODE ###

from heapq import heappush, heappop
sx,sy,gx,gy=map(int,input().split())
n=int(input())
g = [[] for i in range(n+2)]
data=[(sx+sy*1j,0)]
for i in range(n):
    a,b,c=map(int,input().split())
    data.append((a+b*1j,c))
data.append((gx+gy*1j,0))

for i in range(n+2):
    for j in range(i+1,n+2):
        tmp=abs(data[i][0]-data[j][0])-data[i][1]-data[j][1]
        g[i].append((tmp,j))
        g[j].append((tmp,i))

dist=[2828427127 for i in range(n+2)]
visited=[False for i in range(n+2)]
dist[0]=0
que=[]
heappush(que,(0,0))

while que:
    c,v=heappop(que)
    if visited[v]:
        continue
    visited[v]=True
    for x in g[v]:
        if visited[x[1]]:
            continue
        tmp=x[0]+c if not x[0]<0 else c
        if tmp<dist[x[1]]:
            dist[x[1]]=tmp
            heappush(que,(tmp,x[1]))
print(dist[n+1])
list=[int(i) for i in input().split()]
list1=sorted(list)
if list1=[5,5,7]:
  print('YES')
else:
  print('NO')

### FIXED CODE ###

a,b,c,=map(int,input().split())
list1=[a,b,c]
if list1==[5,7,5]:
    print("YES")
elif list1==[7,5,5]:
    print("YES")
elif list1==[5,5,7]:
    print("YES")
else:
    print("NO")
N, M = map(int, input().split())
matrix=[[0]*N for i in range(N)]
for i in range(M):
    a, b = map(int, input().split())
    matrix[a-1][b-1]=1
    matrix[b-1][a-1]=1
import itertools 
count=0
for i in itertools.permulations(range(N)):
    if i[0]==0:
        for j in range(N-1):
            result=1
            result*=matrix[i[j]][i[j+1]]
            if result=1:
                count+=1
    else:
        break
print(count)

### FIXED CODE ###


import itertools

N, M = map(int, input().split())
adj_matrix = [[0]* N for _ in range(N)]

for i in range(M): #隣接行列
    a, b = map(int, input().split())
    adj_matrix[a-1][b-1] = 1
    adj_matrix[b-1][a-1] = 1

cnt = 0

for each in itertools.permutations(range(N)):
    if each[0] != 0:
        break
    factor = 1
    for i in range(N-1):
        factor *= adj_matrix[each[i]][each[i+1]]
    cnt += factor

print(cnt)
from fractions import gcd
import math
import numpy as np
N = list(map(int, input().split()))
g = gcd(N[0], N[1])
original_g = g
max_prime = g + 2
primes = np.ones(max_prime)
#print(g+1, primes.shape)
primes[0:2] = 0
#print(primes)
for i in range(2, max_prime):
  if primes[i] and i * 2 < g + 2:
    primes[i*2::i] = 0
    #print(i, primes)
    
primes = np.arange(max_prime)[primes == 1]
#print(primes)

factor = []
for i in primes:
  if g % i == 0:
    #print(g)
    factor.append(i)

#print(g, original_g, factor)
print(len(factor) + 1)


### FIXED CODE ###

from fractions import gcd
import math
import numpy as np
N = list(map(int, input().split()))
g = gcd(N[0], N[1])

def factorize(g):
  factor = []
  for i in range(2, int(np.sqrt(g))+2):
    if g % i != 0:
      continue
    while g % i == 0:
      g //= i
    factor.append(i)
  if g != 1:
    factor.append(g)
  return factor
print(len(factorize(g))+1)
import re
import numpy as np

H,W,K = map(int,input().split())
grid = [[0 for i in range(W+1)]]
for i in range(H):
  S = input()
  grid.append([0]+[ int(S[i]) for i in range(W) ])

#累積和gridの作成
#行について
for i in range(H+1):
  for j in range(W):
    grid[i][j+1] += grid[i][j]
#列について
for j in range(W+1):
  for i in range(H):
    grid[i+1][j] += grid[i][j]   

min_cnt = 10011
#横の区切りを作る
for h in range(2**(H-1)):
  cnt = 0
  #二進数の文字列を取得
  bin_str = format(h,"0{}b".format(H-1)) 
  #区切りのインデックスリスト
  l_p =[1]+[ x.start()+2 for x in re.finditer("1",bin_str) ] +[H+1]

  #cntに区切りの分だけ付け加える
  cnt = cnt + len(l_p) - 2
  
  ws = 0
  for w in range(1,W+1):
    for k in range(len(l_p)-1):
      if grid[l_p[k+1]-1][w]- (grid[l_p[k]-1][w]+grid[l_p[k+1]-1][ws]-grid[l_p[k]-1][ws]) > K:
        cnt = cnt + 1
        ws = w-1
        break    
  min_cnt = min(min_cnt,cnt)

###
print(min_cnt)        

### FIXED CODE ###

import re

H,W,K = map(int,input().split())
grid = [[0 for i in range(W+1)]]
for i in range(H):
  S = input()
  grid.append([0]+[ int(S[i]) for i in range(W) ])

#累積和gridの作成
#行について
for i in range(H+1):
  for j in range(W):
    grid[i][j+1] += grid[i][j]
#列について
for j in range(W+1):
  for i in range(H):
    grid[i+1][j] += grid[i][j]   

min_cnt = (H-1)*(W-1)
#横の区切りを作る
for h in range(2**(H-1)):
  cnt = 0
  #二進数の文字列を取得
  bin_str = format(h,"0{}b".format(H-1)) 
  #区切りのインデックスリスト
  l_p =[1]+[ x.start()+2 for x in re.finditer("1",bin_str) ] +[H+1]

  #cntに区切りの分だけ付け加える
  cnt = cnt + len(l_p) - 2
  
  ws = 0
  for w in range(1,W+1):
    for k in range(len(l_p)-1):
      if grid[l_p[k+1]-1][w]-grid[l_p[k+1]-1][w-1] > K:
        min_cnt=(H-1)*(W-1)+1
      if grid[l_p[k+1]-1][w]- (grid[l_p[k]-1][w]+grid[l_p[k+1]-1][ws]-grid[l_p[k]-1][ws]) > K:
        cnt = cnt + 1
        ws = w-1
        break    
  min_cnt = min(min_cnt,cnt)

###
print(min_cnt)
N = int(input())
c = input()

first_R = c.index('R')
num_R = c.count('R')

print(first_R+c[first_R:first_R+num_R].count('W'))


### FIXED CODE ###

N = int(input())
c = input()

num_R = c.count('R')

print(c[:num_R].count('W'))
n = int(input())
if n>63:
    print(64):
elif n>31:
    print(32)
elif n>15:
    print(16)
elif n>7:
    print(8)
elif n>3:
    print(4)
elif n>1:
    print(2)
else:
    print(1)

### FIXED CODE ###

n = int(input())
if n>63:
    print(64)
elif n>31:
    print(32)
elif n>15:
    print(16)
elif n>7:
    print(8)
elif n>3:
    print(4)
elif n>1:
    print(2)
else:
    print(1)
import collections

def count_defaultdict(it):
    counter = collections.defaultdict(int)
    for x in it:
        counter[x] += 1
    return dict(counter)
  
n = int(input())
l = list(map(int, input().split()))
all_sum = 0
count = count_defaultdict(l)
for k, v in count:
    all_sum += v * (v - 1) // 2
for i in range(len(l)):
    if count[l[i]] > 1:
        v = count[l[i]]
        print(all_sum - v * (v-1) // 2 + (v-1) * (v-2)//2)
    else:
        print(all_sum)

### FIXED CODE ###

import collections

def count_defaultdict(it):
    counter = collections.defaultdict(int)
    for x in it:
        counter[x] += 1
    return dict(counter)

_ = int(input())
l = list(map(int, input().split()))
all_sum = 0
count = count_defaultdict(l)
for _, v in count.items():
    all_sum += v * (v - 1) // 2
for i in range(len(l)):
    if count[l[i]] > 1:
        v = count[l[i]]
        print(all_sum - v * (v-1) // 2 + (v-1) * (v-2)//2)
    else:
        print(all_sum)
n = str(input())
wa = 0

for i in range(len(n)):
	n[i] = int(n[i])
	wa += n[i]

if wa % 9 == 0:
	print('Yes')
else:
	print('No')

### FIXED CODE ###

n = str(input())
wa = 0

for i in range(len(n)):
	wa += int(n[i])

if wa % 9 == 0:
	print('Yes')
else:
	print('No')
r = input()
ans = r * r * 3
print(ans)

### FIXED CODE ###

r = int(input())

ans = r * r * 3

print(ans)
#include <iostream>
using namespace std;

int main ()
{
	long n, a;
	long ret = 1;
	bool flag = true;

	cin >> n;

	for (int i=0; i<n; i++) {
		cin >> a;
		if (a == 0) {
			cout << 0 << endl;
			return 0;
		}
		ret *= a;
		if (ret <= 0 || 1000000000000000000 < ret) {
			flag = false;
		}
	}

	if (flag == false) {
		cout << -1 << endl;
	} else {
		cout << ret << endl;
	}

	return 0;
}


### FIXED CODE ###

n = int(input())
MX = 10 **18
a = list(map(int, input().split()))
for x in a:
    if x == 0:
        print(0)
        exit(0)
ans = 1
for x in a:
    ans *= x
    if ans > MX:
        print(-1)
        exit(0)
print(ans)
# -*- coding: utf-8 -*-
n = int(input())
a = list(map(int(input().strip().split())))

a.sort(reverse=True)

alice = 0
bob = 0
for i in range(n-1):
    if i % 2 is 0:
        alice = alice + int(a[i])
    else:
        bob = bob + int(a[i])

ans = alice - bob
        
print(ans)

### FIXED CODE ###

n = int(input())
a = input().strip().split()
a = [ int(a[i]) for i in range(len(a)) ]

a.sort(reverse=True)

alice = 0
bob = 0
for i in range(n):
    if i % 2 is 0:
        alice = alice + int(a[i])
    else:
        bob = bob + int(a[i])
        
print(alice - bob)
def gcd(a, b):
    c = a%b
    while(c != 0):
        a = b
        b = c
        c = a%b
    return b

def answer(s, t):
    a = len(s)
    b = len(t)
    if a < b:
        temp = a
        a = b
        b = temp
    gcdAB = gcd(a, b)
    if gcdAB == 1:
        return a*b
    else:
        stack = 0
        c = (a*gcdAB)//b
        for i in range(b):
            if s[i+stack] != t[i]:
                return -1
            stack += c
        return a*gcdAB

sl, tl = map(int, input().split())
s = input()
t = input()
print(answer(s, t))

### FIXED CODE ###

def gcd(a, b):
    c = a%b
    while(c != 0):
        a = b
        b = c
        c = a%b
    return b

def answer(s, t):
    a = len(s)
    b = len(t)
    if s[0] != t[0]:
        return -1
    if a < b:
        temp = a
        a = b
        b = temp
        temp = s
        s = t
        t = temp
    gcdAB = gcd(a, b)
    if gcdAB == 1:
        return a*b
    else:
        stack = 0
        sl = (gcdAB * (a//gcdAB) * (b//gcdAB))
        aJump = sl//a
        bJump = sl//b
        for i in range(b):
            if stack%aJump == 0:
                if s[stack//aJump] != t[i]:
                    return -1
            stack = bJump*(i+1)
        return sl
                

sl, tl = map(int, input().split())
s = input()
t = input()
print(answer(s, t))
S = input()
n = len(S)
isKaibun = True
for i in range(n//2):
    if(S[i] != S[n-i-1] or S[i] != S[n//2-i-1] or S[n//2+i+a1] != S[n//2-i-1]):
        isKaibun = False
        break
if(isKaibun):
    print("Yes")
else:
    print("No")

### FIXED CODE ###

S = input()
n = len(S)
isKaibun = True
for i in range(n//2):
    if(S[i] != S[n-i-1] or S[i] != S[n//2-i-1] or S[n//2+i+1] != S[n//2-i-1]):
        isKaibun = False
        break
if(isKaibun):
    print("Yes")
else:
    print("No")
import bisect

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

L=sorted(L)

ans=0
for i in range(N-1):
    for k in range(i+1,N-1):
        a=L[i]+L[k]
        b=bisect.bisect_left(L,a)
        ans=ans+(b-k-1)

print(ans)

### FIXED CODE ###

import bisect

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

L=sorted(L)

ans=0
for i in range(N-1):
    for k in range(i+1,N-1):
        a=L[i]+L[k]
        b=bisect.bisect_left(L,a)
        ans=ans+(b-k-1)

print(ans)
k = int(input())
def gcd1 (a, b):
    while True:
        if (a < b):
            a, b = b, a
        c = a%b
        if (c == 0):
            return (b)
        else:
            a = b
            b = c

def gcd2 (a, b, c):
    tmp = gcd1(a, b)
    ans = gcd1(tmp, c)
    return (ans)

count = 0
for i in range(k):
    for j in range(i, k):
        for l in range(j, k):
            tmp = gcd(i + 1, j + 1, l + 1)
            if (i == j == l):
                count = count + tmp
            elif (i == j or j == l):
                count = count + tmp*3
            else:
                count = count + tmp*6
print(count)


### FIXED CODE ###

k = int(input())
def gcd1 (a, b):
    while True:
        if (a < b):
            a, b = b, a
        c = a%b
        if (c == 0):
            return (b)
        else:
            a = b
            b = c

count = 0
for i in range(k):
    for j in range(k):
        tmp = gcd1(i + 1, j + 1)
        if (tmp == 1):
            count = count + k
        else:
            for l in range(k):
                tmp2 = gcd1(tmp, l + 1)
                count = count + tmp2

print(count)
n = input()
list = []
for i in range(n):
    list.append(input())

min = list[0]
max = list[0]
dif = []
for i in range(n):
    for j in range(i - 1):
        if list[j] < min:
            min = list[j]
            dif.append(list[i] - min)
    if dif[i] > max:
        max = dif[i]

print max

### FIXED CODE ###

N = int(raw_input())
min = int(raw_input())
max = int(raw_input())
dif = max - min
if max < min:
    min = max

for i in range(N - 2):
    R = int(raw_input())
    if R - min > dif:
        dif = R - min
    if R < min:
        min = R

print dif
from collections import Counter
N = int(input())

A = list(map(int, input().split()))
if all(a == 0 for a in A):
        print('Yes')
elif N % 3:
    print('No')
else:
    n = N//3
    CA = Counter(A)
    ans = 'Yes'
    t = []
    for k, v in CA.items():
        if v != n:
            ans = 'No'
        t.append(k)
        
    if not (t[0]^t[1] == t[2] and t[2]^t[1] == t[0] and t[0]^t[2] == t[1]):
        ans = 'No'
    print(ans)

### FIXED CODE ###

from collections import Counter
N = int(input())

A = list(map(int, input().split()))
if all(a == 0 for a in A):
        print('Yes')
elif N % 3:
    print('No')
else:
    n = N//3
    CA = Counter(A)
    ans = 'Yes'
    t = []
    for k, v in CA.items():
        if not v % n:
            t.append(k)
        
    if len(t) == 3 and (t[0]^t[1] == t[2] and t[2]^t[1] == t[0] and t[0]^t[2] == t[1]):
        ans = 'Yes'
    elif len(t) == 2 and (t[0] == 0 or t[1] == 0):
        ans = 'Yes'
    else:
        ans = 'No'
        
    print(ans)
N = int(input())
A = list(map(int,input().split()))

x = 1


for i in A:
  x = x*i  

if (x<=1000000000000000000) :
    print(x)
else:
    print(-1)
    

### FIXED CODE ###

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

print(A*B)
n,m,k = map(int,input().split())
for a in range(n+1):
  for b in range(m+1):
    if k = a*m+b*n-2*a*b:
      print('Yes')
      exit()
print('No')

### FIXED CODE ###

n,m,k = map(int,input().split())
for a in range(n+1):
  for b in range(m+1):
    if k == a*m+b*n-2*a*b:
      print('Yes')
      exit()
print('No')
a = input()
if a = A :
	print('T')
elif a = T :
	print('A')
elif a = C :
	print('G')
else:
	print('C')

### FIXED CODE ###

a = input()
if a is 'A' :
	print('T')
elif a is 'T' :
	print('A')
elif a is 'C' :
	print('G')
else:
	print('C')
import math
A, B, C, D = map(int, input().split())

def lcm(a,b):
    return a*b//math.gcd(a,b)

b_n = B//C + B//D - B//lcm(C,D)
a_n = (A-1)//C + (A-1)//D - (A-1)//lcm(C,D)
ans_n = b_n - a_n
print(int(B-A+1-ans_n))

### FIXED CODE ###

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

def lcm(a,b):
    return a*b//fractions.gcd(a,b)

b_n = B//C + B//D - B//lcm(C,D)
a_n = (A-1)//C + (A-1)//D - (A-1)//lcm(C,D)
ans_n = b_n - a_n
print(int(B-A+1-ans_n))
n,a,b = map(int,input().split())
inf = 10**9 +7
ans = pow(2,n,inf)-1
def conbi(n,k):
  if n-k < k:
    k = n-k
  x = 1
  y = 1
  for i in range(k):
    x *= n-i
    x = x%inf
    y *= i+1
    y = y%inf
    ans1 = x* pow(y,inf-2,inf)%inf
  return ans1
print(conbi(n,a))
sol = ans - conbi(n,a)- conbi(n,b)
print(sol)

    

### FIXED CODE ###

n,a,b = map(int,input().split())
inf = 10**9 +7
ans = pow(2,n,inf)-1
def conbi(n,k):
  if n-k < k:
    k = n-k
  x = 1
  y = 1
  for i in range(k):
    x *= n-i
    x = x%inf
    y *= i+1
    y = y%inf
  ans = x* pow(y,inf-2,inf)%inf
  return ans
ans  -= conbi(n,a) + conbi(n,b)
ans = ans%inf
print(ans)