Harryxun/stf_run huggingface dataset:
N = int(input())
LR = []
p = 0
max_L = 0
q = 0
min_R = 10**9 + 1

for i in range(N):
    L, R = map(int, input().split())
    R += 1
    LR.append((L, R))
    if L > max_L:
        p = i
        max_L = L
    if R < min_R:
        q = i
        min_R = R

if p == q:
    print(max(r - l for l, r in LR) + max(min_R - max_L, 0))
    exit()

L1, R1 = LR[p]
L2, R2 = LR[q]
LR = [(L, R) for i, (L, R) in enumerate(LR) if i != p and i != q]
LR.sort(key=lambda x: (x[1], x[0]), reverse=True)

ans1 = max(R - L for L, R in LR) + max(min_R - max_L, 0)

n = len(LR) + 1
min_sr = [R1] * n
max_tl = [L2] * n

for i in range(1, n):
    min_sr[i] = min(min_sr[i-1], LR[i-1][1])
    max_tl[n-i-1] = max(max_tl[n-i], LR[n-i-1][0])

ans2 = max(max(r - L1, 0) + max(R2 - l, 0) for r, l in zip(min_sr, max_tl))

print(max(ans1, ans2))


### FIXED CODE ###

N = int(input())
LR = []
p = 0
max_L = 0
q = 0
min_R = 10**9 + 1

for i in range(N):
    L, R = map(int, input().split())
    R += 1
    LR.append((L, R))
    if L > max_L:
        p = i
        max_L = L
    if R < min_R:
        q = i
        min_R = R

ans1 = max(R - L for L, R in LR) + max(min_R - max_L, 0)

if N == 2:
    print(sum(R - L for L, R in LR))
    exit()

if p == q:
    print(ans1)
    exit()

L1, R1 = LR[p]
L2, R2 = LR[q]
LR = [(L, R) for i, (L, R) in enumerate(LR) if i != p and i != q]
LR.sort(key=lambda x: (x[1], x[0]), reverse=True)

n = len(LR) + 1
min_sr = [R1] * n
max_tl = [L2] * n

for i in range(1, n):
    min_sr[i] = min(min_sr[i-1], LR[i-1][1])
    max_tl[n-i-1] = max(max_tl[n-i], LR[n-i-1][0])

ans2 = max(max(r - L1, 0) + max(R2 - l, 0) for r, l in zip(min_sr, max_tl))

print(max(ans1, ans2))
N=int(input())
p=[]
for i in range(N):
    p.append(list(map(int, input().split())))
q=[]
for i in range(N):
    for j in range(N-i):
        q.append(abs(p[i][0]-p[i+j][0])+abs(p[i][1]-p[i+j][1]))
print(max(q))


### FIXED CODE ###

x=int(input())
print(1 if x==0 else 0)
coding: utf-8

import bisect
import math

N, M = (int(v) for v in input().split())

seen = {}
WA = {}

acs = 0
was = 0

for i in range(M):
    q, tmp = input().split()
    if tmp == "AC":
        if q not in seen:
            acs += 1
            if q not in WA:
                WA[q] = 0
            was += WA[q]
            seen[q] = 1
    else:
        if q not in WA:
            WA[q] = 1
        else:
            WA[q] += 1

print (acs, was)



### FIXED CODE ###

#coding: utf-8

import bisect
import math

N, M = (int(v) for v in input().split())

seen = {}
WA = {}

acs = 0
was = 0

for i in range(M):
    q, tmp = input().split()
    if tmp == "AC":
        if q not in seen:
            acs += 1
            if q not in WA:
                WA[q] = 0
            was += WA[q]
            seen[q] = 1
    else:
        if q not in WA:
            WA[q] = 1
        else:
            WA[q] += 1

print (acs, was)
S = list(input())
T = list(input())

cnt = 0

for i in range(0,3):
  if S[i] == T[i]:
    cnt += 1

pirn(cnt)
  


### FIXED CODE ###

S = list(input())
T = list(input())

cnt = 0

for i in range(0,3):
  if S[i] == T[i]:
    cnt += 1

print(cnt)
ret = 0
S = input()
T = input()
print(len[S[i] for i in range(len(S)) if S[i] != T[i]])

### FIXED CODE ###

ret = 0
S = input()
T = input()
print(len([S[i] for i in range(len(S)) if S[i] != T[i]]))
A=list(map(int,input().split()))
for i in range(1,6):
    if A[i]==0:
        print(i)

### FIXED CODE ###

A=list(map(int,input().split()))
for i in range(1,6):
    if A[i-1]==0:
        print(i)
n,k,q= list(map(int, input().split()))
lis=[k]*n
for i in range(q):
    a=int(input())
    a-=1
    lis=map(lambda x: x-1, lis)
    lis[a]+=1
for i in range(n):
    if lis[i]>0:
        print("Yes")
    else:
        print("No")


### FIXED CODE ###

n,k,q= list(map(int, input().split()))
lis=[k-q]*n
for i in range(q):
    a=int(input())
    a-=1
    lis[a]+=1
    
for i in range(n):
    if lis[i]>0:
        print("Yes")
    else:
        print("No")
s = input()

print(s[0] + len(s[1:-1]) + s[-1])


### FIXED CODE ###

s = input()

print(s[0] + str(len(s[1:-1])) + s[-1])
import sys

def I(): return(int(sys.stdin.readline()))
def LI(): return([int(x) for x in sys.stdin.readline().split()])

def main():
    N = I()
    S = sorted(LI(),reverse=True)

    flag = [True]*len(S)
    cur = []
    cur.append(S[0])
    flag[0] = False

    for i in range(N):
        j = 0
        jM = len(cur)
        for k in range(len(S)):
            if flag[k] and S[k]<cur[j]:
                nxt.append(S[k])
                j+=1
                flag[k] = False
                if j==jM:
                  break
        else:
            return("No")
        cur.sort(reverse=True)
    return("Yes")

if __name__ == "__main__":
    print(main())


### FIXED CODE ###

import sys

def I(): return(int(sys.stdin.readline()))
def LI(): return([int(x) for x in sys.stdin.readline().split()])


def main():
    N = I()
    S = sorted(LI(),reverse=True)

    flag = [True]*len(S)

    cur = []
    cur.append(S[0])
    flag[0] = False

    for i in range(N):
        nxt = [x for x in cur]
        j = 0

        for k in range(len(S)):
            if j >= len(cur):
                break
            elif flag[k] and S[k]<cur[j]:
                nxt.append(S[k])
                j+=1
                flag[k] = False
        if len(cur) != j:
            return("No")
        cur = sorted(nxt,reverse=True)
    return("Yes")

if __name__ == "__main__":
    print(main())
X = input()
if X > 30:
  print("Yes")
else:
  print("No")

### FIXED CODE ###

X = int(input())
if X >= 30:
    print("Yes")
else:
    print("No")
data = [
    [[0 for r in range(10)] for f in range(3)] for b in range(4)
]

# ??\?????????????????????????????§????????????????????????????????????
count = int(input())
for c in range(count):
    c, f, r, v = [int(i) for i in input().split]
    data[c - 1][f - 1][r - 1] += v


for bi, b in enumerate(data):
    for f in b:
        for r in f:
            print(' {0}'.format(r), end='')

        print()

    if bi < 3:
        print('#' * 20)

### FIXED CODE ###

data = [
    [[0 for r in range(10)] for f in range(3)] for b in range(4)
]
    
count = int(input())
for c in range(count):
    b,f,r,v = [int(i) for i in input().split()]
    data[b-1] [f-1] [r-1] += v
    
for bi, b in enumerate(data):
    for f in b:
        for r in f:
            print(' {0}'.format(r), end='')
        print()
    if bi < 3:
        print('#' * 20)
S = input()
if S.str.islower():
  print("a")
else:
  print("A")

### FIXED CODE ###

S = input()
if S.islower():
  print("a")
else:
  print("A")
L, R = map(int, input().split())
if R - L >= 2019 :
    print(0)
list = []
else :
    for i in range(L, R+1):
    list.append(i % 2019)
list_sort = sorted(list)
l = list_sort[0] * list_sort[1]
print(l % 2019)


### FIXED CODE ###

L, R = map(int, input().split())
if R - L >= 2019 :
    print(0)

else :
    t = []
    for i in range(L, R):
        for j in range(i + 1, R + 1) :
            t.append((i * j) % 2019)
    print(min(t))
N,K = [int(x) for x in input().split()]
count = [0]*(K+1)
ans = 0
mod = 1000000007
for i in range(K,0,-1):
    kosuu = pow(K//i,N,mod)
    if K // i >= 2:
        for j in range(K//i,1,-1):
            kosuu -= count[j*i]
    ans += i*kosuu
    count[i] = kosuu
print(ans%mod)

### FIXED CODE ###

import sys
sys.setrecursionlimit(2000000000)
N = int(input())
import math
l = [int(x) for x in input().split()]
tobi = [0]*(math.ceil(N/2))
tobi[0] = l[0]
for i in range(1,math.ceil(N/2)):
    tobi[i] = tobi[i-1] + l[i*2]
from functools import lru_cache
@lru_cache(maxsize=1000000000)
def motomeru(x,y):
    if y == 0 or x == 0 or x == 1:
        return 0
    elif x % 2 == 0:
        return max(motomeru(x-2,y-1)+l[x-1],tobi[math.floor((x-1)/2)])
    else:
        return max(motomeru(x-2,y-1)+l[x-1],motomeru(x-1,y))
print(motomeru(N,N//2))
def main():
    N = int(input())
    A = list(map(int, input().split()))
    Q = int(input())

    answer = sum(A)
    numNumberDict = {}
    Aset = set(A)
    
    for Ai in Aset:
        numNumberDict[Ai] = A.count(Ai)
        
    for i in range(Q):
        B, C = list(map(int, input().split()))
        answer = answer + (int(C) - int(B)) * numNumberDict[B]

        numNumberDict[C] = numNumberDict[C] + numNumberDict[B]
        numNumberDict[B] = 0

        print(answer)

if __name__ == "__main__":
    main()

### FIXED CODE ###

import sys

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

    answer = sum(A)
    setA = set(A)
    numNumberList = [0] * 100001

    for Ai in A:
        numNumberList[Ai] = numNumberList[Ai] + 1    

    for i in range(Q):
        B, C = list(map(int, sys.stdin.readline().split()))
        answer = answer + (int(C) - int(B)) * numNumberList[B]

        numNumberList[C] = numNumberList[C] + numNumberList[B]
        numNumberList[B] = 0

        print(answer)

if __name__ == "__main__":
    main()
N, Y = map(int, input().split())
done = False
for i in range(N+1):
  a = i
  for j in (N+1-a):
    b = j
    c = N -i -j
    sum = 10000*a + 5000 * b + 1000 *c
    if sum == Y:
      done = True
      print(a, b, c)
if not done:
  print(-1, -1, -1)

### FIXED CODE ###

N, Y = map(int, input().split())
done = False
for i in range(N+1):
  a = i
  for j in range(N+1-a):
    b = j
    c = N -i -j
    sum = 10000*a + 5000 * b + 1000 *c
    if sum == Y:
      done = True
      print(a, b, c)
  if done:
    break
        
if not done:
  print(-1, -1, -1)
import numpy as np
import heapq

def dijkstra_heapq(graph,node_count,start_index):
    #INF = np.sum(graph) + 1
    INF = 10**9+7
    node = [[INF,i] for i in range(node_count)]
    const_node = [[INF,-1] for i in range(node_count)]

    node[start_index][0] = 0
    heapq.heapify(node)

    print(const_node)

    while len(node) > 0:
        sub_dist,min_node_dex = heapq.heappop(node)
        const_node[min_node_dex][0] = sub_dist

        for i in range(len(node)):
            if g[min_node_dex][node[i][1]] > 0:
                    new_dist = sub_dist + g[min_node_dex][node[i][1]]
                    if new_dist < node[i][0]:
                        node[i][0] = new_dist
                        const_node[node[i][1]][1] = min_node_dex

        print(const_node)

    return const_node

def dijkstra(graph,node_count,start_index):
    INF = 10**9+7
    node = [INF] * node_count
    conf = [0] * node_count
    root = [-1] * node_count

    node[start_index] = 0
    count = 0
    while sum(conf) < node_count:

        change = False

        min_node_dex = -1
        min_node_val = INF
        for i in range(node_count):
            if conf[i] == 0:
                if node[i] < min_node_val:
                    min_node_val = node[i]
                    min_node_dex = i
        conf[min_node_dex] = 1
        for i in range(node_count):
            if conf[i] == 0:
                if g[min_node_dex][i] > 0:
                    new_dist = node[min_node_dex] + g[min_node_dex][i]
                    if new_dist < node[i]:
                        node[i] = new_dist
                        root[i] = min_node_dex
                        change = True

        #print(node)
        #print(conf)
        #print(root)
        count += 1
        if not change:
            break
        #if count >= 10:
        #    break
    return root

n, m = map(int, input().split())
r = []
g = np.zeros((n,n),dtype=np.int64)

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

#c = dijkstra_heapq(g,n,0)
c = dijkstra(g,n,0)

#print(np.array(c) + 1)

ans = []
for i in range(1,n):
    if c[i] >= 0:
        ans.append(c[i]+1)
    else:
        print('No')
        exit()

print('Yes')
for i in range(len(ans)):
    print(ans[i])

#print(np.array(c)+1)


### FIXED CODE ###

import queue
n, m = map(int, input().split())
g = [[] for _ in range(n+1)]

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

#print(g)

root = [0] * n
count = 0
q = queue.Queue()
q.put(0)
root[0] = 1
count += 1
while not q.empty():
    p = q.get()
    for i in g[p+1]:
        if root[i-1] <= 0:
            q.put(i-1)
            root[i-1] = p + 1
            count += 1
            #print(p,i,count,root)
            if count >= n:
                break


if count < n:
    print('No')
    exit()
else:
    print('Yes')
    for i in range(1,n):
        print(root[i])
a = input()
b = input()

print(a < b)
print(a > b)
print(a == b)

### FIXED CODE ###

a, b = map(int, input().split())
if a < b:
    print("a < b")
elif a > b:
    print("a > b")
else:
    print("a == b")
print(( N // X + 1 ) * T )

### FIXED CODE ###

N, X, T = map(int,input().split())

A = N % X

if ( A ) == 0:
    print(( N // X ) * T )
elif ( N % X ) != 0:
    print(( N // X + 1 ) * T )
def main():
    n=int(input())
    lst=list(map(int,input().split()))
    mod=10**9+7
    sm=1
    color=[0,0,0]
    for x in lst:
        sm*=color.count(x)
        sm%=mod
        color[color.index(x)]+=1
    print(sm)

main()

### FIXED CODE ###

def main():
    n=int(input())
    lst=list(map(int,input().split()))
    mod=10**9+7
    sm=1
    color=[0,0,0]
    for x in lst:
        if x not in color : sm=0;break
        sm*=color.count(x)
        sm%=mod
        color[color.index(x)]+=1
    print(sm)

main()
x,y = map(int,input().split())
if x == 0 and y > 0:
    print(y-x)
elif x == 0 and y < 0:
    print(1+abs(x+y))
elif y == 0 and x > 0:
    print(1+abs(x+y))
elif y == 0 and x < 0:
    print(y-x)
    
elif 0 < x and x < y:
    print(y-x)
elif 0 < x and x > y:
    #print(abs(y+x)+1)
elif x < 0 and y > 0:
    print(abs(y+x)+1)
elif y < 0 and x < y:
    print(y-x)
elif x < 0 and y < x:
    print(2+abs(x-y))



### FIXED CODE ###

x,y = map(int,input().split())
if x == 0 and y > 0:
    print(y-x)
elif x == 0 and y < 0:
    print(1+abs(x+y))
elif y == 0 and x > 0:
    print(1+abs(x+y))
elif y == 0 and x < 0:
    print(y-x)
elif x < 0 and y < x:
    print(2+abs(x-y))
elif 0 < x and x < y:
    print(y-x)
elif 0 < y and x > y:
    print(2+abs(x-y))
elif 0 > y and x > y:
    print(abs(y+x)+1)
elif x < 0 and y > 0:
    print(abs(y+x)+1)
elif y < 0 and x < y:
    print(y-x)
def get_input():
    N = int(input())
    a = [int(input()) for i in range(N)]
    return N,a

MOD =998244353
def solve(N,a):
    sum_a = sum(a)
    dp = [[0 for _ in range(sum_a+1)] for _ in range(N+1)]
    dp[0][0] = 1
    for j in range(1,N+1):
        dp[j][0] = (2 * dp[j-1][0])%MOD

    for i in range(1,N+1):
        for j in range(1,sum_a+1):
            if j-a[i-1]>=0:
                dp[i][j] = ( dp[i][j] + dp[i-1][j]*2 +dp[i-1][j-a[i-1]])%MOD
            else:
                dp[i][j] = ( dp[i][j] + dp[i-1][j]*2 )%MOD
    all_combination = 1
    for i in range(N):
        all_combination = (all_combination*3) %MOD
    half_sum_a = sum_a //2 if sum_a %2 == 0 else sum_a//2+1 
    bigger_than_half = sum(dp[N][half_sum_a:])
    if sum_a %2 == 0:
        half_dp = [[0 for _ in range(sum_a+1)] for _ in range(N+1)]
        half_dp[:,0] = 1
        for i in range(1,N+1):
            for j in range(1,sum_a+1):
                if j-a[i-1]>=0:
                    half_dp[i][j] = ( half_dp[i][j] + half_dp[i-1][j] +half_dp[i-1][j-a[i-1]])%MOD
                else:
                    half_dp[i][j] = ( half_dp[i][j] + half_dp[i-1][j] )%MOD
        half_half = half_dp[N][half_sum_a]
        
    else:
        half_half = 0
    return int(all_combination - 3* bigger_than_half + 3* half_half)%MOD

    
if __name__ =="__main__":
    N,a = get_input()
    ans = solve(N,a)
    print(ans)

### FIXED CODE ###

import numpy as np
N = int(input())
a = np.array([int(input()) for i in range(N)])
MOD =998244353
sum_a = np.sum(a)
dp =  np.zeros((N+1,sum_a+1))
half_dp = np.zeros((N+1,sum_a//2+1))
dp[0][0] = 1
half_dp[0][0] = 1

for i in range(1,N+1):
    dp[i,:] += dp[i-1,:]*2 %MOD
    dp[i,a[i-1]:] +=  dp[i-1, :-a[i-1]]%MOD
    half_dp[i,:] +=  half_dp[i-1,:] %MOD
    half_dp[i,a[i-1]:] += half_dp[i-1,:-a[i-1]]%MOD

all_combination = 3**N %MOD
half_sum_a = sum_a //2 if sum_a %2 == 0 else sum_a//2+1 
bigger_than_half = np.sum(dp[N][half_sum_a:])
half_half = half_dp[N][half_sum_a] if sum_a%2==0 else 0
ans = int(all_combination - 3* bigger_than_half + 3* half_half)%MOD
print(ans)
r = raw_intput()
import math
print(math.pi * r)

### FIXED CODE ###

import math
t = int(input())
print(t * math.pi * 2)
X=int(input())
N=X//100
M=X%100
A=[0,1,2,3,4,5]
dp=[[0]*(M+1) for i in range(N+1)]
dp[0][0]=1
for i in range(N):
    for k in range(M+1):
        dp[i+1][k]|=dp[i][k]
        if k>=A[i]:
            dp[i+1][k]|=dp[i][k-A[i]]
print(dp[N][M])

### FIXED CODE ###

X=int(input())
d,m=divmod(X,100)
print(1 if m<=(d*5) else 0)
import math
pi=round(math.pi,7)
r=input()
print(2*r*pi r*r*pi)


### FIXED CODE ###

import math
pi=math.pi
r=float(input())
print("{:.5f} {:.5f}".format(r*r*pi,2*r*pi))
import sys

def quartet(h, w):
    global flag
    if 0 <= h <= 11 and 0 <= w <= 11:
        if mapp[h][w] == '1':
            mapp[h][w] = '$'
            flag = True
            bigbang(h, w)
        elif mapp[h][w] == '0' or mapp[h][w] == '$':
            return
    else:
        return

def bigbang(h, w):
    quartet(h, w+1)
    quartet(h-1,w)
    quartet(h, w-1)
    quartet(h+1, w)

while True:
    try:
        mapp = []
        for line in sys.stdin:
            lis = []
            for char in line.rstrip():
                lis.append(char)
            else:
                mapp.append(lis)
        
        flag = False
        count = 0
        for h in range(12):
            for w in range(12):
                quartet(h, w)
                if flag == True:
                    count += 1
                flag = False
        else:
            print count
        if raw_input == '':
            continue
    except EOFError:
        break

### FIXED CODE ###

def f1():
    t = 0
    for y in range(len(M)):
        for x in range(len(M[0])):
            if M[y][x] == '1':
                f2(x, y)
                t += 1
    return t


def f2(x, y):
    if x < 0 or len(M[0]) == x or y < 0 or len(M) == y:
        return
    if M[y][x] == '1':
        M[y][x] = '0'
        f2(x, y-1)
        f2(x, y+1)
        f2(x+1, y)
        f2(x-1, y)


M = []
while True:
    try:
        line = input()
        if line == '':
            print(f1())
            M = []
        else:
            M.append(list(line))
    except EOFError:
        print(f1())
        break
N = int(input())
data = [0]*N
for i in range(0,N): data[i] = int(input())

import math

ans = data[0]
for i in range(0,N):
    ans = ans*data[i] // math.gcd(ans,data[i])

print(ans)

### FIXED CODE ###

N = int(input())
data = [0]*N
for i in range(0,N): data[i] = int(input())

import fractions

ans = data[0]
for i in range(0,N):
    ans = ans*data[i] // fractions.gcd(ans,data[i])

print(ans)
def dfs(g_idx, idx):
    if gps[idx] != 'o':
        return
    gps[idx] = g_idx
    mbs[g_idx] += 1
    for f in fs[idx]:
        dfs(g_idx, f)


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

fs = {}
bs = {}
for _ in range(m):
    a, b = map(int, input().split())
    if a in fs:
        fs[a].append(b)
    else:
        fs[a] = [b]
    if b in fs:
        fs[b].append(a)
    else:
        fs[b] = [a]
for _ in range(k):
    c, d = map(int, input().split())
    if c in bs:
        bs[c].append(d)
    else:
        bs[c] = [d]
    if d in bs:
        bs[d].append(c)
    else:
        bs[d] = [c]

g_idx = 0
gps = ['o'] * (n + 1)
mbs = {}

for idx in range(1, n + 1):
    if gps[idx] != 'o':
        continue
    gps[idx] = g_idx
    mbs[g_idx] = 1
    for f in fs[idx]:
        dfs(g_idx, f)
    g_idx += 1

out = ''
for idx in range(1, n + 1):
    ans = mbs[gps[idx]] - 1 - len(fs[idx])
    for b_idx in bs.get(idx, []):
        if gps[b_idx] == gps[idx]:
            ans -= 1
    out += str(ans) + ' '
print(out.rstrip())


### FIXED CODE ###

class UnionFind:
    def __init__(self, n):
        self.parent = [-1] * n

    def find(self, x):
        if self.parent[x] < 0:
            return x
        else:
            self.parent[x] = self.find(self.parent[x])
            return self.parent[x]

    # xとyの属する集合の併合
    def unite(self, x, y):
        x = self.find(x)
        y = self.find(y)

        if x == y:
            return

        # sizeの大きいほうがx
        if self.parent[x] > self.parent[y]:
            x, y = y, x
        self.parent[x] += self.parent[y]
        self.parent[y] = x

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

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


n, m, k = map(int, input().split())
num_friends = [0 for _ in range(n + 1)]
blocks = [[] for _ in range(n + 1)]
uf = UnionFind(n + 1)

for i in range(m):
    a, b = map(int, input().split())
    num_friends[a] += 1
    num_friends[b] += 1
    uf.unite(a, b)

for i in range(k):
    c, d = map(int, input().split())
    blocks[c].append(d)
    blocks[d].append(c)

out = ''
for i in range(1, n + 1):
    ans = uf.size(i) - num_friends[i] - 1
    for block in blocks[i]:
        if uf.same(i, block):
            ans -= 1
    out += str(ans) + ' '
print(out.strip())
n,K = map(int,input().split())
X, Y = [], []
dots = []
for _ in range(n):
    x,y = map(int,input().split())
    dots.append((x,y))
    X.append(x)
    Y.append(y)
X.sort()
Y.sort()
ans = float('inf')
for i in range(n):
    for j in range(i+1, n):
        for k in range(n):
            for l in range(k+1, l):
                x1,x2 = X[i], X[j]
                y1,y2 = Y[k], Y[l]
                cnt = 0
                for dot in dots:
                    if x1<=dot[0]<=x2 and y1<=dot[1]<=y2:
                        cnt += 1
                if cnt >= K:
                    ans = min(ans, (x2-x1)*(y2-y1))
print(ans)

### FIXED CODE ###

n,K = map(int,input().split())
X, Y = [], []
dots = []
for _ in range(n):
    x,y = map(int,input().split())
    dots.append((x,y))
    X.append(x)
    Y.append(y)
X.sort()
Y.sort()
ans = float('inf')
for i in range(n):
    for j in range(i+1, n):
        for k in range(n):
            for l in range(k+1, n):
                x1,x2 = X[i], X[j]
                y1,y2 = Y[k], Y[l]
                cnt = 0
                for dot in dots:
                    if x1<=dot[0]<=x2 and y1<=dot[1]<=y2:
                        cnt += 1
                if cnt >= K:
                    ans = min(ans, (x2-x1)*(y2-y1))
print(ans)
a,b,c = map(int, raw_input().split(" "))
if a <= b :
    if a <= b <= c :
        print(a,b,c)
    elif a <= c <= b :
        print(a,c,b)
    else :
        print(c,a,b)
else b <= a :
    if b <= a <= c :
        print(b,a,c)
    elif b <= c <= a :
        print(b,c,a)
    else :
        print(c,b,a)

### FIXED CODE ###

al = list(map(int, input().split()))
al = sorted(al)
print(al[0],al[1],al[2])
import math
from functools import reduce
def gcd(x):
    return reduce(math.gcd, x)


a = int(input())
l = []
for i in range(1, a+1):
    for j in range(1, a+1):
        for k in range(1, a+1):
            l.append(gcd([i, j, k]))
print(sum(l))

### FIXED CODE ###

n = input()
print('Yes' if '7' in n else 'No')