Harryxun/stf_run huggingface dataset:
r,c,k = map(int,input().split())
dp = [[[0 for _ in range(4)] for _ in range(c+1)] for _ in range(r+1)]
g = [[0]*(c+1) for _ in range(r+1)]
for _ in range(k):
    a,b,v = map(int,input().split())
    g[a][b] = v

for i in range(r+1):
    for j in range(c+1):
        for m in range(4):
            here = dp[k][i][j]
            if i + 1 <= r:
                dp[0][i + 1][j] = max(dp[0][i + 1][j], here)
                dp[1][i + 1][j] = max(dp[1][i + 1][j], here + g[i + 1][j])
            if j + 1 <= c:
                dp[k][i][j + 1] = max(dp[k][i][j + 1], here)
                if k < 3:
                    dp[k + 1][i][j + 1] = max(dp[k + 1][i][j + 1], here + g[i][j + 1])
# ans = 0
            # tmp  =dp[i][j][m]
            # if i+1<=r:
            #     dp[i+1][j][0] = max(tmp,dp[i+1][j][0])
            #     dp[i+1][j][1] = max(dp[i+1][j][1],tmp + g[i+1][j])
            # if j+1<=c:
            #     dp[i][j+1][m] = max(dp[i][j+1][m],tmp)
            #     if m<3:
            #         dp[i][j+1][m+1] = max(dp[i][j+1][m+1],tmp + g[i][j+1]) 
print(max(dp[-1][-1]))
 

### FIXED CODE ###

import sys

R, C, K = map(int, input().split())
item = [[0] * (C + 1) for _ in range(R + 1)]  # dp配列と合わせるために, 0行目, 0列目を追加している.
for s in sys.stdin.readlines():
    r, c, v = map(int, s.split())
    item[r][c] = v

dp = [[[0] * (C + 1) for _ in range(R + 1)] for _ in range(4)]
for i in range(R + 1):
    for j in range(C + 1):
        for k in range(4):
            here = dp[k][i][j]
            if i + 1 <= R:
                dp[0][i + 1][j] = max(dp[0][i + 1][j], here)
                dp[1][i + 1][j] = max(dp[1][i + 1][j], here + item[i + 1][j])
            if j + 1 <= C:
                dp[k][i][j + 1] = max(dp[k][i][j + 1], here)
                if k < 3:
                    dp[k + 1][i][j + 1] = max(dp[k + 1][i][j + 1], here + item[i][j + 1])
ans = 0
for k in range(4):
    ans = max(ans, dp[k][-1][-1])
print(ans)
H, W = map(int, input())
h, w = map(int, input())
print((H-h)*(W-w))

### FIXED CODE ###

H, W = map(int, input().split())
h, w = map(int, input().split())
print((H-h)*(W-w))
n,k = map(int,input().split())
mp = [0]*(k+1)
for i in range(k):
  a = list(map(int,input().split()))
  for j in a:
    mp[j]+=1
res = 0
for i in range(1,k+1):
  if mp[i]==0:
    res+=1
print(res)

### FIXED CODE ###

n,k = map(int,input().split())
mp = [0]*(n+1)
for i in range(k):
  d = int(input())
  a = list(map(int,input().split()))
  for j in a:
    mp[j]+=1
res = 0
for i in range(1,n+1):
  if mp[i]==0:
    res+=1
print(res)
n = int(input())
*a,=map(int, input().split())
mapa=[0]*(10**6+1)

n0 = 10**6
primes = [0]*(n0+1)
for i in range(2, int(n0**0.5+1)):
    if primes[i]==0:
        x=i
        multi=1
        while x<=n0:
            if primes[x]==0:
                primes[x]=i
            x//=multi
            multi+=1
            x*=multi

def func(m):
    while m>1:
        mapa[primes[m]]+=1
        pm=primes[m]
        while m>1 and m%pm==0:
            m//=pm

for ai in a:
    func(ai)

tmp=max(mapa)

if tmp==n:
    print('not coprime')
elif tmp>1:
    print('setwise coprime')
else:
    print('pairwise coprime')

### FIXED CODE ###

n = int(input())
*a,=map(int, input().split())
mapa=[0]*(10**6+1)

from bisect import bisect_left

n0 = 10**6
primes = set(range(2, n0+1))
for i in range(2, int(n0**0.5+1)):
    primes.difference_update(range(i*2, n0+1, i))
primeind=[0]*(10**6+1)
for p in primes:
    primeind[p]=1

def isPrime(m):
    return primeind[m]==1

def func(m):
    for i in range(2,int(m**0.5)+1):
        if isPrime(m):
            break
        if m%i==0:
            mapa[i]+=1
        while m%i==0:
            m//=i
        if m<i:
            break
    if m>1:
        mapa[m]+=1

for ai in a:
    func(ai)

tmp=max(mapa)
#print(mapa[:20])
if tmp==n:
    print('not coprime')
elif tmp>1:
    print('setwise coprime')
else:
    print('pairwise coprime')
a=input()
s=int(a)
if a<86400 and a>=0:

    h=int(s/3600)
    m=int((s-h*3600)/60)
    s=s-h*3600-m*60

    print(h,m,s)

else:
    exit()

### FIXED CODE ###

a=input()
s=int(a)
if s<86400 and s>=0:

    h=int(s/3600)
    m=int((s-h*3600)/60)
    s=s-h*3600-m*60
    print("{0}:{1}:{2}".format(h,m,s))

else:
    exit()
s=raw_input()
t=raw_input()

ls=len(s)
lt=len(t)

if lt==ls+1 and t.startswith(s):
    print ('Yes')
else:
    print("No")




### FIXED CODE ###

s=input()
t=input()

ls=len(s)
lt=len(t)

if lt==ls+1 and t.startswith(s):
    print ('Yes')
else:
    print("No")
a=int(input())
b=(a+1)/2*a
if a%2=1:
  print(0.5)
else:
  print(b)

### FIXED CODE ###

a=int(input())
b=(a+1)/(2*a)
if a%2==0:
  print(0.5)
else:
  print(b)
n=int(input())

a==int(n%9)

if a==0:
   print(Yes)
else:
  print(No)
  

### FIXED CODE ###

n=int(input())

a=int(n%9)

if a==0:
   print("Yes")
else:
  print("No")
N, T = map(int, input().split(" "))
roots = [tuple(map(int, input().split(" "))) for i in range(N)]
roots = sorted(roots, key=lambda x:x[1])

ans = 1000000000
for i in range(len(roots)):
  ii = i
  csum = 0
  tsum = 0
  
  while True:
    c, t = roots[ii]
    tsum += t

    if T >= tsum:
      ii += 1
      csum += c
    else:
      break
    
  if ans > csum and csum != 0:
      ans = csum
  else:
      tsum = 0
      break

print('TLE' if ans == 1000000000 else ans)

### FIXED CODE ###

import sys
N, T = map(int, sys.stdin.readline().split(" "))
roots = [tuple(map(int, sys.stdin.readline().split(" "))) for i in range(N)]

from operator import itemgetter
#roots = sorted(roots, key=lambda x:x[1])
roots = (sorted(roots, key=itemgetter(1, 0)))

def dfs(i, csum, tsum):
    if tsum + roots[i][1] <= T:
        if i+1 == N:
          return csum + roots[i][0]
        else:
          return dfs(i+1, csum+roots[i][0], tsum+roots[i][1])
    else:
        return 100000000 if csum == 0 else csum

ans = 100000000
for ii in range(N):
  csum = dfs(ii, 0, 0)
  if ans > csum:
    ans = csum
  if csum == 100000000:
    is_do = False
    break

if ans == 100000000:
    print('TLE')
else:
    print(ans)
D = int(input())
print(Christmas if D == 25, Christmas Eve if D ==24, Christmas Eve Eve if D == 23, Christmas Eve Eve Eve else)

### FIXED CODE ###

D = int(input())
x = "Christmas" + (" Eve")*(25-D)
print(x)
#Union Find

#xの根を求める
def find(x):
    if par[x] < 0:
        return x
    else:
        par[x] = find(par[x])
        return par[x]
#xとyの属する集合の併合
def unite(x,y):
    x = find(x)
    y = find(y)
    
    if x == y:
        return False
    else:
        #sizeの大きいほうがx
        if par[x] > par[y]:
            x,y = y,x
        par[x] += par[y]
        par[y] = x
        return True

#xとyが同じ集合に属するかの判定
def same(x,y):
    return find(x) == find(y)

#xが属する集合の個数
def size(x):
    return -par[find(x)]

import numpy as np
n, m = map(int, input().split( ))

#初期化
#根なら-size,子なら親の頂点
par = [-1]*n

for i in range(m):
    x,y=map(int,input().split(' '))
    unite(x,y)

# print(par)
print(-min(par))

### FIXED CODE ###

#Union Find

#xの根を求める
def find(x):
    if par[x] < 0:
        return x
    else:
        par[x] = find(par[x])
        return par[x]
#xとyの属する集合の併合
def unite(x,y):
    x = find(x)
    y = find(y)
    
    if x == y:
        return False
    else:
        #sizeの大きいほうがx
        if par[x] > par[y]:
            x,y = y,x
        par[x] += par[y]
        par[y] = x
        return True

#xとyが同じ集合に属するかの判定
def same(x,y):
    return find(x) == find(y)

#xが属する集合の個数
def size(x):
    return -par[find(x)]

import numpy as np
n, m = map(int, input().split( ))

#初期化
#根なら-size,子なら親の頂点
par = [-1]*n

for i in range(m):
    x,y=map(int,input().split(' '))
    unite(x-1,y-1)

# print(par)
print(-min(par))
import sys

args = sys.argv
num  = int(args[1])
print( num * num * num )

### FIXED CODE ###

x = int( input() )
print( x ** 3 )
N = int(input())
Ls= list(map(int, input().split()))
count=0
for i in range(len(N)):
  for j in range(i,len(N)):
    for k in range(j,len(N)):
      tmp=[Ls[i],Ls[j],Ls[k]]
      if sum(tmp) < 2 * max(tmp):
        count+=1

print(count)
      

### FIXED CODE ###

N = int(input())
L= list(map(int, input().split()))
Ls = list(set(L))
res=[]
for i in range(len(Ls)):
  for j in range(i+1,len(Ls)):
    for k in range(j+1,len(Ls)):
      tmp=[Ls[i],Ls[j],Ls[k]]
      if sum(tmp) > 2*max(tmp):
        res.append(tmp)
        
c=0
for i in range(len(res)):
  ctmp=L.count(res[i][0])*L.count(res[i][1])*L.count(res[i][2])
  c+=ctmp
print(c)
while True:
    try:
        ip+=raw_input().lower()
    except:
        break
alphabet = 'abcdefghijklmnopqrstuvwxyz'
for i in alphabet:
    print i +' : '+ str(ip.count(i))

### FIXED CODE ###

ip=''
while True:
    try:
        p=raw_input()
    except:
        break
    ip+=p.lower()
alphabet = 'abcdefghijklmnopqrstuvwxyz'
for i in alphabet:
    print i +' : '+ str(ip.count(i))
import math
import numpy as np
def lcm(x, y):
    return (x * y) // math.gcd(x, y)

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

# arr = np.linspace(A,B,1)
a1 = A // C
a2 = A // D

b1 = B // C
b2 = B // D 

ab1 = b1 - a1
ab2 = b2 - a2
if A % C == 0 and B % C == 0:
    ab1+=1
if A % D == 0 and B % D == 0:
    ab2+=1

lc = lcm(C,D)
a3 = A // lc
b3 = B // lc
ab3 = b3 - a3
res = ab1 + ab2 - ab3
print(abs(A-B)-res)

### FIXED CODE ###

from fractions import gcd

def lcm(x, y):
    return (x * y) // gcd(x, y)

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

ab1 = B // C -  (A-1) // C
ab2 = B // D -  (A-1) // D

lcd = lcm(C,D)

ab3 = B//lcd - (A-1)//lcd

ans = (B-A+1) - (ab1+ab2-ab3)

print(ans)
a=input()
b=input()
c=int(b)//2
D=int(a)+int(c)
print(D)

### FIXED CODE ###

import sys

def solve(a, b):
    return(int(a)+int(b)//2)


def readQuestion():
    ws = sys.stdin.readline().strip().split()
    a = int(ws[0])
    b = int(ws[1])
    return (a, b)

def main():
    print(solve(*readQuestion()))

# Uncomment before submission
main()
n=int(input())
A=list(map(int,input().split()))
q=0
Z=[]
for b in range(max(A)-min(A)):
  q=0
  for j in range(n):
    q+=abs(A[j]-b-min[A]-j-1)
  Z.append(q)
print(min(Z))


### FIXED CODE ###

n=int(input())
if n%2==0:
  print(n)
else:
  print(n*2)
N = int(input())
h = [int(i) for i in input().split()]

def solve(n):
    if n==0:
        return 0
    elif n==1:
        return abs(h[1]-h[0])
    else:
        return min(abs(h[n]-h[n-1])+solve(n-1),abs(h[n]-h[n-2])+solve(n-2))

print(solve(N-1))

### FIXED CODE ###

N = int(input())
h = [int(i) for i in input().split()]
c = [0]*N

c[0]=0
c[1]=abs(h[1]-h[0])
for i in range(2,N):
    c[i] = min(abs(h[i]-h[i-1])+c[i-1],abs(h[i]-h[i-2])+c[i-2])

print(c[N-1])
n = int(input())
lst = [[-1 for _ in range(n)] for _ in range(n)]
for _ in range(n):
    c = int(input())
    for c1 in range(c):
        x, y = map(int, input().split())
        x -= 1
        lst[_][x] = y

ans = 0
for bit in range(n**2 - 1):
    flg = True
    for a in range(n):
        if (bit >> a) & 1:
            for x in range(n):
                if lst[a][x] != -1 and ((bit >> x) & 1) != lst[a][x]:
                    flg = False
                    break
if flg:
  ans = max(ans, bin(bit).count('1'))
print(ans)
    


### FIXED CODE ###

n = int(input())
lst = []
for _ in range(n):
    a = int(input())
    lst.append([[int(i) for i in input().split()] for _ in range(a)])
m = 0
for i in range(2 ** n):
    a = True
    for j in range(n):
        if i >> j & 1:
            for x, y in lst[j]:
                if (i >> (x - 1) & 1) != y:
                    a = False
                    break
    if a:
        m = max(m, bin(i).count('1'))
print(m)
h,w=map(int,input().split())
field=[]
nfield=[[] for i in range(h)]
for i in range(n):
  field.append(input())
def check(a,b):
  num=0
  if field[a][b]=="#":
    return
  for i in range(a-1,a+2):
    for j in range(b-1,b+2):
      try:
        if field[i][j]=="#":
          num+=1
      except:
        pass
  return num
for i in range(h):
  for j in range(w):
    if field[i][j]==".":
      nfield[i][j]=check(i,j)
    else:
      nfield[i][j]="#"
for i in range(h):
  for j in range(w):
    if j != w-1:
      print(nfield[i],end="")
    else:
      print(nfield[i])


### FIXED CODE ###

h,w=map(int,input().split())
field=[]
nfield=[[] for i in range(h)]
for i in range(h):
  field.append(input())
def check(a,b):
  num=0
  if field[a][b]=="#":
    return
  for i in range(a-1,a+2):
    for j in range(b-1,b+2):
      try:
        if j !=-1 and i!=-1 and field[i][j]=="#":
          num+=1
      except:
        pass
  return num
for i in range(h):
  for j in range(w):
    if field[i][j]==".":
      nfield[i].append(check(i,j))
    else:
      nfield[i].append("#")
for i in range(h):
  for j in range(w):
    if j != w-1:
      print(nfield[i][j],end="")
    else:
      print(nfield[i][j])
import sys
import numpy as np
def main():
    input = sys.stdin.readline
    N = int(input())
    ans = (1 + (N - 1)) / 2 * (N - 1)

    if N <= 1e07:
      a = np.arange(start=1, step=1, stop=N+1)
      if N %2 == 1:
        bol = (a % ((N+1)/2) >= a)
        ans += np.sum((a % ((N+1)/2)[bol] - a[bol])
      else:
        bol = (a % (N/2) >= a)
        ans += np.sum((a % (N/2)[bol] - a[bol])
       
      #print(a[bol])
      #print(bol)
      #print(np.any(bol))
      #if np.any(bol):
      #print((N % a)[bol])
      #print(((N % a)[bol]))
      #print(a[bol])
      #ans += np.sum((N % a)[bol] - a[bol])

    print(int(ans))

if __name__ == '__main__':
    main()

### FIXED CODE ###

import sys
import numpy as np
def main():
    input = sys.stdin.readline
    N = np.int64(input())
    #print(N)
    #ans = np.int64((1 + (N - 1)) / 2 * (N - 1))
    ans = (1 + (N - 1)) * (N - 1) // 2
    print(int(ans))
if __name__ == '__main__':
    main()
from collections import defaultdict
mod = 10**9+7
N = int(input())
d = defaultdict(list)
for i in range(N-1):
    x, y = map(int, input().split())
    d[x-1].append(y-1)
    d[y-1].append(x-1)
    
def f(i):
    if flag[i]:
        return
    flag[i] = 1
    dp[i][0] = 1 #white
    dp[i][1] = 1 #black
    for j in d[i]:
        if not flag[j]:
            f(j)
            dp[i][0] = dp[i][0]*(dp[j][0] + dp[j][1])%mod
            dp[i][1] = dp[i][1]*dp[j][0]%mod
flag = [0] * N
dp = [[0,0] for i in range(N)]
f(0)
print(dp[0][0]+dp[0][1])

### FIXED CODE ###

import sys
sys.setrecursionlimit(10**9)
mod = 10**9+7
N = int(input())
G = [[] for i in range(N)]
for i in range(N-1):
    x, y = map(int, input().split())
    G[x-1].append(y-1)
    G[y-1].append(x-1)
    
def dfs(i, pi):
    b = 1
    w = 1
    for ni in G[i]:
        if ni == pi:
            continue
        [nb, nw] = dfs(ni, i)
        b *= nw
        b %= mod
        w *= nw + nb
        w %= mod
    return [b, w]

print(sum(dfs(0, -1))%mod)
A, B, C, D = map(int, input().split())
A -= 1
X = gcd(C, D)
print(B - B//C - B//D + B//(C*D//X) - A + A//C + A//D -A//(C*D//X))

### FIXED CODE ###

from fractions import gcd
A, B, C, D = map(int, input().split())
A -= 1
X = gcd(C, D)
print(B - B//C - B//D + B//(C*D//X) - A + A//C + A//D -A//(C*D//X))
R = int,input()
print( 3.14*2*R )

### FIXED CODE ###

import math
R = int(input())
print(2*math.pi*R)
import math
con = 0;
n = int(input())
nn = n**4
a = [0]*nn

m = int(math.sqrt(n) // 1);
for x in range(1,m+1):
    for y in range(1,m+1):
        for z in range(1,m+1):
            s = x**2 + y**2 + z**2 + x*y + y*z + z*x;
            a[s-1] += 1;


for v in range(n):
    print(a[v]);

### FIXED CODE ###

import math
con = 0;
n = int(input())
a = [0]*n

m = int(math.sqrt(n) // 1);
for x in range(1,m+1):
    for y in range(1,m+1):
        for z in range(1,m+1):
            s = x**2 + y**2 + z**2 + x*y + y*z + z*x;
            if s <= n:
                a[s-1] += 1;


for v in range(n):
    print(a[v]);
N = int(input())
A = list(map(int, input().split()))
n = [0] * N
for i in range( N):
    n[A[i]-1] += 1

for j in range(N):
    print(n[j])

### FIXED CODE ###

N = int(input())
A = list(map(int, input().split()))
n = [0] * N
#A_2 A_3 ... A_N とA_1をのぞいて続くのでN-1となる
for i in range(N-1):
    n[A[i]-1] += 1

for j in range(N):
    print(n[j])
a, b, h = list(map(int, input().split()))
print((a + b) * h // 2)

### FIXED CODE ###

a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)
N = int(input())
a = [list() for i in range(N+1)]
for i in range(N):
    b = int(input())
    a[i+1].append(b)

ans = 0
check = []
tmp = 1
check.append(tmp)
flag = False
while(1):
    tmp = a[tmp]
    ans += 1
    if tmp==2:
        flag = True
        break
    if tmp in check:
        break
if flag:
    print(ans)
else:
    print(-1)

### FIXED CODE ###

N = int(input())
a = []
for i in range(N):
    b = int(input())
    a.append(b)
ans = 0
tmp = 1
flag = False
while(1):
    tmp = a[tmp-1]
    ans += 1
    if tmp==2:
        flag = True
        break
    if ans > N:
        break
if flag:
    print(ans)
else:
    print(-1)
def solve():
    global h, dp, K
    N, K = map(int,input().split())
    h = list(map(int,input().split()))
    dp = [float('inf')] * N

    dp[0] = 0
    print(rec(N-1))

def rec(i):
    if dp[i] != float('inf'):
        return dp[i]
    if i == 0:
        return 0
    
    res = float('inf')
    for j in range(1,K+1):
        if i-j < 0:
            break
        res = min(res, rec(i-j) + abs(h[i] - h[i-j]))
    
    dp[i] = res
    return res

if __name__ == '__main__':
    solve()


### FIXED CODE ###

def solve():
    N, K = map(int, input().split())
    h = list(map(int, input().split()))

    dp = [float('inf')] * N
    dp[0] = 0
    for i in range(1, N):
        lst = []
        for k in range(1,i+1):
            if k > K:
                break
            lst.append(abs(h[i] - h[i-k]) + dp[i-k])
        
        lst.append(dp[i])
        dp[i] = min(*lst)
    
    print(dp[N-1])

if __name__ == '__main__':
    solve()
print(3.1415*R*2)

### FIXED CODE ###

print(3.1415*int(input())*2)
#!/usr/bin/python3                                                                                                                                                                                          

import itertools

if __name__=='__main__':
    str = input()
    signs_comb = list(itertools.combinations_with_replacement([1, -1], 3))
    for signs in signs_comb:
        sum = int(str[0])
        for i in range(3):
            sum += signs[i] * int(str[i + 1])
        if sum == 7:
            sign_char = ['+' if i==1 else '-' for i in signs]
            break
    exp = str[0] + sign_char[0] + str[1] + sign_char[1] + str[2] + sign_char[2] + str[3] + '=7'
    print(exp)



### FIXED CODE ###

#!/usr/bin/python3                                                                                                                                                                                          

import itertools

if __name__=='__main__':
    str = input()
    signs_comb = list(itertools.product([1, -1], repeat=3))
    for signs in signs_comb:
        sum = int(str[0])
        for i in range(3):
            sum += signs[i] * int(str[i + 1])
        if sum == 7:
            sign_char = ['+' if i==1 else '-' for i in signs]
            break
    exp = str[0] + sign_char[0] + str[1] + sign_char[1] + str[2] + sign_char[2] + str[3] + '=7'
    print(exp)
import sys
sys.setrecursionlimit(100000)

nCr = {}


def cmb(n, r):
    if r == 0 or r == n:
        return 1
    if r == 1:
        return n
    if (n, r) in nCr:
        return nCr[(n, r)]
    nCr[(n, r)] = cmb(n - 1, r) + cmb(n - 1, r - 1)
    return nCr[(n, r)]


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

for i in range(1, K + 1):
    print((cmb(N - K + 1, i) %
           (10**9 + 7)) * (cmb(K - 1, i - 1) %
                           (10**9 + 7)))


### FIXED CODE ###

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


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

for i in range(1, K + 1):
    if N - K + 1 < i:
        print(0)
    else:
        print((cmb(N - K + 1, i) * cmb(K - 1, i - 1)) % (10**9 + 7))
N = int(input())
A = list(map(int,input().split()))
A = sorted(A)
A_ = []
tmp = A[1]-A[0]
A_1 = [i for i in A]
A_1 = [i%A[0] for i in A_1]
A_2 = [2*i for i in A]
A_2 = [i%A[0] for i in A_2]
A_3 = [i for i in A]
A_3 = [i%tmp for i in A_3]
A_ = A_1 + A_2 + A_3 
A_ = sorted(set(A_))
if A_ == [0]*len(A_):
  print(A[0])
else:
  print(A_[1])

### FIXED CODE ###

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

A_tmp=A[0]
for i in A[1:]:
  if i%A_tmp != 0:
    A_tmp = i%A_tmp
    
while(1):
  tmp = [x%A_tmp for x in A if x%A_tmp != 0]
  if sum(tmp) != 0:
    A_tmp = min(tmp)
  else:
    break
print(A_tmp)
a=list(int(input().split()))
b=list(int(input().split()))

s=(a[0]-b[0])*(a[0]-b[0])
print(s)

### FIXED CODE ###

a=list(map(int,input().split()))
b=list(map(int,input().split()))
print((a[0]-b[0])*(a[1]-b[1]))
def main():
    N = int(input())
    A, B = [], []
    AB = []
    for i in range(N):
        a, b = map(int, input().split())
        A.append(a)
        B.append(b)
        AB.append([a, b])

    AB.sort(key=lambda x: x[1])

    time = 0
    while (len(AB) > 0):
        flag = True
        a, b = AB
        if time + a <= b:
            time += a
            AB.pop(0)
            flag = False
        if flag:
            break
    if len(AB) == 0:
        print('Yes')
    else:
        print('No')

if __name__ == "__main__":
    main()

### FIXED CODE ###

def main():
    N = int(input())
    A, B = [], []
    AB = []
    for i in range(N):
        a, b = map(int, input().split())
        A.append(a)
        B.append(b)
        AB.append([a, b])

    AB.sort(key=lambda x: x[1])

    time = 0
    count = 0
    for i in range(N):
        flag = True
        a, b = AB[i]
        if time + a <= b:
            time += a
            count += 1
            flag = False
        if flag:
            break

    if count == N:
        print('Yes')
    else:
        print('No')    

if __name__ == "__main__":
    main()
n = int(input())
e = sorted([[int(i) for i in input().split()] for i in range(n)], key=lambda x:x[2])[::-1]

def f():
    for x in range(101):
        for y in range(101):
            flg = True
            H = e[0][2] + abs(x-e[0][0]) + abs(y-e[0][1])
            for e_ in e:
                if H != e_[2] + abs(x-e_[0]) + abs(y-e_[1]):
                    flg = False
                    break
            if flg:
                return (x, y, H)
result = f()
print("{} {} {}".format(result[0], result[1], result[2]) )

### FIXED CODE ###

n = int(input())
e = sorted([[int(i) for i in input().split()] for i in range(n)], key=lambda x:x[2])[::-1]

def f():
    for x in range(101):
        for y in range(101):
            flg = True
            H = e[0][2] + abs(x-e[0][0]) + abs(y-e[0][1])
            for e_ in e:
                if (e_[2] == 0):
                    if H > abs(x-e_[0]) + abs(y-e_[1]):
                        flg = False
                        break
                    else:
                        continue
                
                if H != e_[2] + abs(x-e_[0]) + abs(y-e_[1]):
                    flg = False
                    break
            if flg:
                return (x, y, H)
result = f()
print("{} {} {}".format(result[0], result[1], result[2]) )
import math 

R = int(input())

pai = 3.1415926535

circle_pond = 2*R*math.pai
print(circle_pond)

### FIXED CODE ###

import math 

R = int(input())

circle_pond = 2*R*math.pi
print(circle_pond)