Harryxun/stf_run huggingface dataset:
import sys,math,collections,itertools
    input = sys.stdin.readline

    N=int(input())
    XY = []
    xAve = 0
    yAve = 0
    for _ in range(N):
        x,y=map(int,input().split())
        XY.append([x,y])
        xAve += x
        yAve += y
    xAve = xAve/N
    yAve = yAve/N
    XYnorm = [0]*4

    for x,y in XY:
        nX = x-xAve
        nY = y-yAve
        if nX>=0 and nY>=0:#第1象限
            if XYnorm[0]<= nX+nY:
                XYnorm[0] = nX+nY
                XY0 =[x,y]

        if nX <=0 and nY >=0:#第2象限
            if XYnorm[1]<= -nX+nY:
                XYnorm[1] = -nX+nY
                XY1 =[x,y]
                
        if nX <=0 and nY <=0:#第3象限
            if XYnorm[2]<= -nX-nY:
                XYnorm[2] = -nX-nY
                XY2 =[x,y]
                
        if nX >=0 and nY <=0:#第4象限
            if XYnorm[3]<= nX-nY:
                XYnorm[3] = nX-nY
                XY3 =[x,y]

    try:
        XY01 = abs(XY0[0]-XY1[0])+abs(XY0[1]-XY1[1])
    except:
        XY01=0
        
    try:
        XY02 = abs(XY0[0]-XY2[0])+abs(XY0[1]-XY2[1])
    except:
        XY02=0
    try:
        XY03 = abs(XY0[0]-XY3[0])+abs(XY0[1]-XY3[1])
    except:
        XY03=0
    try:
        XY12 = abs(XY1[0]-XY2[0])+abs(XY1[1]-XY2[1])
    except:
        XY12 = 0
    try:
        XY13 = abs(XY1[0]-XY3[0])+abs(XY1[1]-XY3[1])
    except:
        XY13 = 0
    try:
        XY23 = abs(XY2[0]-XY3[0])+abs(XY2[1]-XY3[1])
    except:
        XY23 = 0
    print(max([XY01,XY02,XY03,XY12,XY13,XY23]))
        


### FIXED CODE ###

import sys,math,collections,itertools
input = sys.stdin.readline

N=int(input())
zmax=-float('inf')
zmin = float('inf')
wmax = -float('inf')
wmin = float('inf')

for _ in range(N):
    x,y=map(int,input().split())
    z=x+y
    w=x-y
    zmax = max(z,zmax)
    zmin = min(z,zmin)
    wmax = max(w,wmax)
    wmin = min(w,wmin)
print(max(zmax-zmin,wmax-wmin))
n = int(input())
a = list(map(int,input().split()))

if 0 in a:
    print(0)
    return
ans = 1
for i in a:
    ans *= i
    if ans >1000000000000000000:
        print(-1)
        return
print(ans)


### FIXED CODE ###

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

if 0 in a:
    print(0)
    exit()
ans = 1
for i in a:
    ans *= i
    if ans > 10**18:
        ans = -1
        break
print(ans)
n = int(input())
r = 1
w = 10**9 + 7
for i in range(n):
  r = r * i / x
  
print(r)

### FIXED CODE ###

n = int(input())
r = 1
w = 10**9 + 7
for i in range(1, n+1):    
  r *= i
  r = (r % w)
  
  
  
print(r)
n, k = map(int,input().split())
d = list(map(int,input().split()))

x = 0
y = 0
while x <4:
    if n // (10**x) >0:
        y = x
    x += 1

i = 0
a = [0]
m = 0
while i <= y:
    a.append(((n//(10**(y-i)))%10))
    i +=1

i = 0
t = 0
while i <= y:
    j = 0
    while j < k:
        if a[y-i+1] == d[j]:
            a[y-i+1] += 1
        if a[y-i+1] == 10:
            a[y-i+1] = 0
            a[y-i] +=1
        j+=1
    i+=1
    if a[0] == 1 and t == 0:
        a[1] = 0
        a[2] = 0
        a[3] = 0
        a[4] = 0
        i = 0
        t = 1
        continue

i = 0
while i <= y + 1:
    m += a[y-i+1]*(10**(i))
    i+=1


print(m)


### FIXED CODE ###

n, k = map(int,input().split())
d = list(map(int,input().split()))

s = 0
while s<k and s == d[s]:
    s += 1

x = 0
y = 0
while x <4:
    if n // (10**x) >0:
        y = x
    x += 1

i = 0
a = [0]
m = 0
while i <= y:
    a.append(((n//(10**(y-i)))%10))
    i +=1

i = 0
t = 0
while i <= y + t:
    j = 0
    while j < k:
        if a[y-i+1] == d[j]:
            a[y-i+1] += 1
            if y-i+1 < y+1:
                a[y-i+2] = s
        if a[y-i+1] == 10:
            a[y-i+1] = 0
            a[y-i] +=1
        j+=1
    i+=1
    if a[0] == 1 and t == 0:
        i = 1
        while i<=y+1:
            a[i] = 0
            i += 1
        i = 0
        t = 1
        continue

i = 0
while i <= y + t:
    m += a[y-i+1]*(10**(i))
    i+=1


print(m)
S=str(input())
if S==Sunny:
  print('Cloudy')
elif S==Rainy:
  print('Sunny')
else:
  print('Rainy')

### FIXED CODE ###

S=input()
list=['Sunny','Cloudy','Rainy']

if S==list[0]:
  print(list[1])
elif S==list[1]:
  print(list[2])
else:
  print(list[0])
import fractions

n, k = map(int, input().split())
array = [int(x) for x in input().split()]

res = fractions.gcd(array[0], array[1])


for i in array[2:]:
    res = math.gcd(res, i)
print("POSSIBLE" if k%res==0 and max(array) >= k else "IMPOSSIBLE")

### FIXED CODE ###

import fractions
import sys

n, k = map(int, input().split())
array = [int(x) for x in input().split()]

if n == 1:
    print("POSSIBLE" if max(array) == k else "IMPOSSIBLE")
    sys.exit()

res = fractions.gcd(array[0], array[1])

for i in array[2:]:
    res = fractions.gcd(res, i)
print("POSSIBLE" if k%res==0 and max(array) >= k else "IMPOSSIBLE")
N = int(input())
t=0
x=0
y=0
for i in range(N)
    nt, nx, ny = map(int, input().split())
    km = abs(nx-x) + abs(ny-y)
    if km > (nt-t) or (km - (nt-t)) % 2 == 1:
        print("No")
        exit(0)
    t, x, y = nt, nx, ny
print("Yes")


### FIXED CODE ###

t, x, y = 0, 0, 0
for i in range(int(input())):
    next_t, next_x, next_y = map(int, input().split())
    diff = abs(x - next_x) + abs(y - next_y)
    if diff > (next_t - t) or (diff - (next_t - t)) % 2 == 1:
        print("No")
        exit(0)
    t, x, y, = next_t, next_x, next_y
print("Yes")
n=int(input())
d = list(map(int, input().split()))
a=0
for i in range(0,n,1):
  if d[i]==d[-1]:
    break
  for j in d[i+1:]:
    a+=d[i]*d[j]
print(a)

### FIXED CODE ###

n=int(input())
d = list(map(int, input().split()))
a=0
for i in range(0,n,1):
  if i==n:
     break
  for j in d[i+1:]:
    a+=d[i]*j
print(a)
n, l = map(int, input().split())
string_list = [input() for i in range(l)]
print("".join(sorted(string_list)))

### FIXED CODE ###

n, l = map(int, input().split())
string_list = sorted([input() for i in range(n)])
print("".join(string_list))
even, odd = map(int,input().split())
print((even*~-n // 2) + (odd*=~-odd // 2))

### FIXED CODE ###

n, m = map(int, input().split())
print((n * ~-n // 2) + (m* ~-m // 2))#n * ~-n == n*(n-1)
n=int(input())
s=input()
c=0
for i in range(1,N):
  x=set(s[:i])
  y=set(s[i:])
  a=x&y
  c=max(c,a)
print(c)


### FIXED CODE ###

n=int(input())
s=input()
c=0
for i in range(1,n):
  x=set(s[:i])
  y=set(s[i:])
  a = len(x & y)
  if a > c:
    c = a
print(c)
import sys
input = sys.stdin.readline
# sys.setrecursionlimit(100000)


def get_prime(N, prime):
    if N < 2:
        return {1: 1}

    i = 2
    while i * i <= N:
        while N % i == 0:
            if i in prime.keys():
                prime[i] += 1
            else:
                prime[i] = 1
            N = N // i
        i += 1
    if N != 1:
        prime[N] = 1
    return prime


def main():
    N = int(input().strip())
    div_table = [1] * (N + 1)
    MOD = 10**9 + 7
    ans = 0
    for i in range(2, N + 1):
        for j in range(i, N + 1, i):
            div_table[j] += 1

    prime = dict()
    prime[1] = 1

    for i in range(1, N + 1):
        if div_table[i] == 2:
            prime = get_prime(i, prime)
    ans = 1
    for k, v in prime:
        ans *= v
        ans %= MOD

    print(ans)


if __name__ == "__main__":
    main()


### FIXED CODE ###

import sys
input = sys.stdin.readline
# sys.setrecursionlimit(100000)


def get_prime(N):
    prime = dict()
    prime[1] = 1
    i = 2
    while i * i <= N:
        while N % i == 0:
            if i in prime.keys():
                prime[i] += 1
            else:
                prime[i] = 1
            N = N // i
        i += 1
    if N != 1:
        prime[N] = 1
    return prime


def main():
    N = int(input().strip())
    div_table = [0] * (N + 1)
    MOD = 10**9 + 7
    ans = 1
    for i in range(2, N + 1):
        for j in range(i, N + 1, i):
            div_table[j] += 1

    prime = dict()
    for i in range(2, N + 1):
        if div_table[i] == 1:
            prime[i] = 0

    for i in range(2, N + 1):
        _prime = get_prime(i)
        for k, v in _prime.items():
            if k == 1:
                continue
            prime[k] += v

    for k, v in prime.items():
        ans *= v + 1
        ans %= MOD

    print(ans)


if __name__ == "__main__":
    main()
a = list(input())
for i in range(len(a)):
    if a[i] == "B":
        if i > 0
            a[i] = ""
            for j in range(i-1, -1, -1):
            if a[j] != "":
                a[j] = ""
print("".join(a))


### FIXED CODE ###

a = input()
b = ""
for i in range(len(a)):
    if a[i] == "0":
        b += "0"
    elif a[i] == "1":
        b += "1"
    else:
        b = b[:-1]
print(b)
n = int(input())
tasks = [list(map(int, input().split())) for i in range(N)]
tasks.sort(key=lambda x: x[1])

time = 0
for task in tasks:
    time += task[0]
    if time > task[1]:
        print("No")
        exit()
print("Yes")

### FIXED CODE ###

n = int(input())
tasks = [list(map(int, input().split())) for i in range(n)]
tasks.sort(key=lambda x: x[1])

time = 0
for task in tasks:
    time += task[0]
    if time > task[1]:
        print("No")
        exit()
print("Yes")
n=int(input())
from collections import deque
q =deque(input())

ans = 0
while q:
    while q[0] == 'R':
        q.popleft()
    while q[-1] == 'W':
        q.pop()
    ans += 1
    q.popleft()
    q.pop()
print(ans)

### FIXED CODE ###

n=int(input())
from collections import deque
q =deque(input())

ans = 0
while q:
    while q and q[0] == 'R' and q:
        q.popleft()
    while q and q[-1] == 'W' and q:
        q.pop()
    if not q:break
    ans += 1
    q.popleft()
    q.pop()
print(ans)
# -*- coding: utf-8 -*-
# 
import math
import sys
import itertools
import numpy as np
 
DIV_NUM = 1000000000 + 7
 
INPUT_NUMS = list(map(int, input().split()))
N=int(INPUT_NUMS[0])
K=int(INPUT_NUMS[1])
 
A = [int(x) for x in input().split()]
AA = np.array(A)
if N==1:
    print(0)
    exit()
 
tree = np.array([0] * (N+1) )
 
# https://atcoder.jp/contests/chokudai_S001/submissions/6789704
def BIT_update(x):
    while x <= N:
        tree[x] += 1
        x += x&(-x)
def BIT_sum(x):
    s = 0
    while x > 0:
        s += tree[x]
        x -= x&(-x)
    return s
 
answer = N*(N-1)//2
for x in AA:
    answer -= BIT_sum(int(x))
    BIT_update(int(x))
 
B = sorted(A)
 
q=0
p=B[0]
r=0
for i in range(1,N):
    if B[i]>p:
        p=B[i]
        r=i
    q += r
 
# print(answer,K)
answer = answer % DIV_NUM
answer = int(answer)
answer = (answer * K) % DIV_NUM
q = q % DIV_NUM
answer = answer + q * K * (K-1) // 2
answer = answer % DIV_NUM
print(answer)
 

### FIXED CODE ###

# -*- coding: utf-8 -*-
# 
import math
import sys
import itertools
import numpy as np

DIV_NUM = 1000000000 + 7

INPUT_NUMS = list(map(int, input().split()))
N=int(INPUT_NUMS[0])
K=int(INPUT_NUMS[1])

A = [int(x) for x in input().split()]
AA = np.array(A)
if N==1:
    print(0)
    exit()

# https://kira000.hatenadiary.jp/entry/2019/02/23/053917
def bubble_sort(A):
    cnt = 0
    for i in range(len(A)):
        for j in range(len(A)-1, i, -1):
            if A[j] < A[j-1]:
                A[j], A[j-1] = A[j-1], A[j]
                cnt += 1
    return cnt

answer = bubble_sort(AA)

B = sorted(A)
q=0
p=B[0]
r=0
for i in range(1,N):
    if B[i]>p:
        p=B[i]
        r=i
    q += r

# print(answer,K)
answer = answer % DIV_NUM
answer = int(answer)
answer = (answer * K) % DIV_NUM
q = q % DIV_NUM
answer = answer + q * K * (K-1) // 2
answer = answer % DIV_NUM
print(answer)
def gcd(m,n):
    while (m % n != 0):
        n,m = m%n,n
    return(n)

def lcm(m,n):
    return(m * n // gcd(m,n))

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

s = input()
t = input()


g = gcd(m,n)

if(g in [n,m]):
    print(-1)
else:
    x = lcm(m,n)
    a = x // n
    b = x // m
    for i in range(x//n):
        ai = 1 + a * i
        bi = 1 + b * i
        if(s[ai] != t[bi]):
            print(-1)
            exit()
    print(lcm(m,n))

### FIXED CODE ###

def gcd(m,n):
    while (m % n != 0):
        n,m = m%n,n
    return(n)

def lcm(m,n):
    return(m * n // gcd(m,n))

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

s = input()
t = input()


g = gcd(m,n)

if(g in [n,m]):
    print(-1)
else:
    x = lcm(m,n)
    a = x // n
    b = x // m
    for i in range(n//b):
        ai = b * i
        bi = a * i
        if(s[ai] != t[bi]):
            print(-1)
            exit()
    print(lcm(m,n))
c_1 = [int(i) for i in input().split()]
c_2 = [int(i) for i in input().split()]
c_3 = [int(i) for i in input().split()]

c1 = [i - min(c_1) for i in c_1]
c2 = [i - min(c_2) for i in c_2]
c3 = [i - min(c_3) for i in c_3]

if c1 == c2 and c2 == c3:
    print("Yes")
else:
    print("No")

### FIXED CODE ###

N = int(input())
A = int(input())

a = N % 500
if a <= A:
    print("Yes")
else:
    print("No")
n = int(input())
base = 10

if n%2 != 0:
  print(0)
else:
  ans = 0
  for i in range(10000)
    ans += n//base
    base *= 5   
  print(ans)
  

### FIXED CODE ###

a = int(input())
b = int(input())
 
print(6-a-b)
N = int(input())

def check(p):
  _N = N
  while _N%p == 0:
    _N //= p
  return (_N-1)%p == 0

n = int(N**0.5) + 1
P0 = set([N])
P1 = set([N-1])
for i in range(2, n+1):
  if (N-1)%i == 0:
    P1.add(i)
    P1.add((N-1)//i)
  if N%i == 0:
    P0.add(i)
    P0.add(N//i)

P2.discard(1)
P1.discard(1)
ans = len(P1)
for p in P0:
  ans += check(p)

print(ans)

### FIXED CODE ###

N = int(input())

def check(p):
  _N = N
  while _N%p == 0:
    _N //= p
  return (_N-1)%p == 0

n = int(N**0.5) + 1
P0 = set([N])
P1 = set([N-1])
for i in range(2, n+1):
  if (N-1)%i == 0:
    P1.add(i)
    P1.add((N-1)//i)
  if N%i == 0:
    P0.add(i)
    P0.add(N//i)

P0.discard(1)
P1.discard(1)
ans = len(P1)
for p in P0:
  ans += check(p)

print(ans)
n = int(input())

xy = [input().split() for i in range(n)]
s = 0
for i in range(n):
    for j in range(i+1, n):
        s += ((xy[i][0]-xy[j][0])**2 + (xy[i][1]-xy[j][1])**2)**0.5
print(s*2/n)

### FIXED CODE ###

n = int(input())

xy = [list(map(int, input().split())) for i in range(n)]
s = 0
for i in range(n):
    for j in range(i+1, n):
        s += ((xy[i][0]-xy[j][0])**2 + (xy[i][1]-xy[j][1])**2)**0.5
print(s*2/n)
n=int(input())
x=0
cnt=0
for i in range(n):
    a=int(input())
    x=max(a,x)
    cnt+=a
if x==1:
    print(first)
else:
    if (a-2)%2==1:
        print("first")
    else:
        print("second")

### FIXED CODE ###

n=int(input())
cnt=0
for i in range(n):
    a=int(input())
    cnt+=(a%2)
if cnt==0:
    print("second")    
else:
    print("first")
from collections import defaultdict

N = int(input())
a = list(map(int, input().split()))
d = defaultdict()
for c in a[1:]:
    d[c] += 1
for i in range(1, N):
    x = a[0]
    y = a[i]
    d[y] -= 1
    for _ in range(N - 2):
        z = x ^ y
        if z in d and d[z] > 0:
            d[z] -= 1
            x = y
            y = z
        else:
            break
    else:
        if a[0] == x ^ y:
            print("Yes")
            exit(0)

print("No")

### FIXED CODE ###

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

if a[N -1] == 0:
    print("Yes")
    exit(0)

if N % 3 == 0:
    i = N // 3
    if a[0] ^ a[i] == a[2 * i]:
        if a[0] == a[i -1] and a[i] == a[2 * i - 1] and a[2 * i] == a[N -1]:
            print("Yes")
            exit(0)

print("No")
a = list(map(int,input().split()))
b = list(map(int,input().split()))
b.sort()

c = []
if len(b) != 1:
  for i in range(len(b) - 1):
    c.append(b[i+1] - b[i])

if len(b) == 1:
  print(1)
  
    
else:  
  for j in range(min(a[0] - 1,a[1]):
    for k in range(len(c)):
      if c[k] == max(c):
        c[k] = 0

  print(sum(c))


### FIXED CODE ###

# coding: utf-8
# Your code here!
a = list(map(int,input().split()))
b = list(map(int,input().split()))
b.sort()

c = []
if len(b) != 1:
  for i in range(len(b) - 1):
    c.append(b[i+1] - b[i])

if len(b) == 1:
  print(0)
  
    
else:  
  c.sort()
  for j in range(min(a[0] - 1,a[1])):
    c[len(c)- 1 - j] = 0
  print(sum(c))
import sys
sys.setrecursionlimit(10**6)
import numpy as np
N, M = map(int, input().split())

MOD = 1000000007
dp = np.zeros(N, dtype = int)
if M != 0:
    A = np.array([int(input()) for _ in range(M)], dtype = int)
    dp[A - 1] = -1

if dp[0] == -1 and dp[1] == -1:
    pass
elif dp[0] == -1:
    dp[1] = 1
elif dp[1] == -1:
    dp[0] = 1
else:
    dp[0] = 1
    dp[1] = 2


if N >= 3:
    for n in range(2, N):
        if dp[n] != -1:
            dp[n] = (max(dp[n-1], 0) + max(dp[n-2], 0)) % MOD

print (dp[-1])


### FIXED CODE ###

import sys
sys.setrecursionlimit(10**6)
import numpy as np
N, M = map(int, input().split())

MOD = 1000000007
dp = np.zeros(N, dtype = int)
if M != 0:
    A = np.array([int(input()) for _ in range(M)], dtype = int)
    dp[A - 1] = -1


if dp[0] == -1 and dp[1] == -1:
    pass
else:
    if dp[0] == -1:
        dp[1] = 1
    elif N >= 2 and dp[1] == -1:
        dp[0] = 1
    elif N >= 2:
        dp[0] = 1
        dp[1] = 2
    else:
        dp[0] = 1


if N >= 3:
    for n in range(2, N):
        if dp[n] != -1:
            dp[n] = (max(dp[n-1], 0) + max(dp[n-2], 0)) % MOD

print (dp[-1])
import sys
N,M=map(int, sys.stdin.readline().split())
ll=float("-inf")
rr=float("inf")
for _ in range(M):
    l,r=map(int, sys.stdin.readline().split())
    ll=max(ll,l)
    rr=min(rr,r)

if ll<=rr:
    print rr-ll+1
else:
    print 0

### FIXED CODE ###

import sys

N,M=map(int, sys.stdin.readline().split())
A=map(int, sys.stdin.readline().split())
A.sort()

B=[ map(int, sys.stdin.readline().split()) for _ in range(M)] 
B.sort(key=lambda x: x[1], reverse=True)

i=0

for b,c in B:
	for i in range(i,N):
		if A[i]<c and 0<b:
			A[i]=c
			b-=1
		if b==0:
			break
	i+=1

print sum(A)
File Edit Options Buffers Tools Help
a, b = gets.chomp.split(" ").to_i
if a < b
    puts "a < b"
elsif a > b
    puts "a > b"
else
    puts "a == b"
end

### FIXED CODE ###

a,b=map(int, raw_input().split())

if a > b:
    print "a > b"
elif a < b:
    print "a < b"
else:
    print "a == b"
# 5
# 3 5 2 1 4
def cum(i):
    res = 0
    while i>0:
        res += bit[i]
        i -= i&-i
    return res

def add(i, x):
    while i<=N:
        bit[i] += x
        i += i&-i

def solve():
    global N,A,bit
    N = int(input())
    A = list(map(int, input().split()))
    bit = [0]*(N+1)

    res = 0
    for i in range(N):
        res += cum(A[i])
        add(A[i], 1)

    print(N*(N-1)//2-res)

    return 0

if __name__ == "__main__":
    solve()




### FIXED CODE ###

import sys  # {{{
import os
import time
import re
from pydoc import help
import string
import math
from operator import itemgetter
from collections import Counter
from collections import deque
from collections import defaultdict as dd
import fractions
from heapq import heappop, heappush, heapify
import array
from bisect import bisect_left, bisect_right, insort_left, insort_right
from copy import deepcopy as dcopy
import itertools
# }}}

# pre-defined{{{
sys.setrecursionlimit(10**7)
INF = 10**20
GOSA = 1.0 / 10**10
MOD = 10**9+7
ALPHABETS = [chr(i) for i in range(ord('a'), ord('z')+1)]  # can also use string module
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LI_(): return [int(x)-1 for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def I(): return int(sys.stdin.readline())
def F(): return float(sys.stdin.readline())
def DP(N, M, first): return [[first] * M for n in range(N)]
def DP3(N, M, L, first): return [[[first] * L for n in range(M)] for _ in range(N)]
from inspect import currentframe
def dump(*args):
    names = {id(v):k for k,v in currentframe().f_back.f_locals.items()}
    print(', '.join(names.get(id(arg),'???')+' => '+repr(arg) for arg in args), file=sys.stderr)
# }}}

def local_input():# {{{
    from pcm.utils import set_stdin
    import sys
    from pathlib import Path
    parentdir = Path(os.path.dirname(__file__)).parent
    inputfile = parentdir.joinpath('test/sample-1.in')
    if len(sys.argv) == 1:
        set_stdin(inputfile)
# }}}

# 5
# 3 5 2 1 4
def cum(i):
    res = 0
    while i>0:
        res += bit[i]
        i -= i&-i
    return res

def add(i, x):
    while i<=N:
        bit[i] += x
        i += i&-i

def pos(a):
    return i

def solve():
    global N,A,bit
    N = int(input())
    A = list(map(int, input().split()))
    bit = [0]*(N+1)

    B = list(set(A))
    B.sort()
    B = [-1] + B

    res = 0
    for i in range(N):
        j = bisect_left(B, A[i])
        res += cum(j)
        add(j, 1)

    print(N*(N-1)//2-res)

    return 0

if __name__ == "__main__":# {{{
    try:
        local_input()
    except:
        pass
    solve()
# vim: set foldmethod=marker:}}}
com=int(input())
if com==1:
  print("Hello World")
else:
  a,b=map(int,input().split())
  print(a+b)

### FIXED CODE ###

n=int(input())

if n == 1:
  print("Hello World")
else:
  a=int(input())
  b=int(input())
  print(a+b)
a=[]
a=input().split()
a.sort()
if a[2]-a[1]==a[1]-a[0]:
	print('YES')
else:
	print('NO')

### FIXED CODE ###

a,b,c=input().split()
d=[]
d.append(int(a))
d.append(int(b))
d.append(int(c))
if d[2]-d[1]==d[1]-d[0]:
	print('YES')
else:
	print('NO')
#http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ALDS1_1_B&lang=jp
#??????????????????????????????
#?????§??¬?´???°???????????????????????????????????¨????????¨?¨????????????????
def gcd(x,y):
    tmp = y
    
    if y > x:
        y = x
        x = tmp

    while not y == 0:
        y = x % y
        x = tmp
        tmp = y

    return x
def main():
    target = [int(a) for a in input().split()]
    print(gcd(a[0], a[1]))
    
if __name__ == "__main__":
    main()

### FIXED CODE ###

#http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ALDS1_1_B&lang=jp
#??????????????????????????????
#?????§??¬?´???°???????????????????????????????????¨????????¨?¨????????????????
def gcd(x,y):
    
    if y > x:
        x, y = y, x

    while not y == 0:
        x, y = y, x % y
    
    return x
def main():
    target = [int(a) for a in input().split()]
    print(gcd(target[0], target[1]))
    
if __name__ == "__main__":
    main()
for x in range(100):

    h1 = int(raw_input())

    h1 = h1**3

    print( str(h1) + "\r\n")



### FIXED CODE ###

import sys
input_line2 = int(sys.stdin.readline())
#print ("\r\n")
print (input_line2**3)
#print ("\r\n")