Harryxun/stf_run huggingface dataset:
k,n=map(int,input().split())
if n==0:
    print(0)
else:
    l=list(map(int,input().split()))
    l.sort()
    k1=[i for i in range(min(l),max(l)+1) if i not in l]
    d={}
    for i in range(len(k1)):
        d[k1[i]]=abs(k1[i]-k)
    k2=min(d,key=d.get)
    print(k2)


### FIXED CODE ###

x,n=map(int,input().split())
l=list(map(int,input().split()))
if x not in l:
    print(x)
elif n==0:
    print(x)
else:
    a=101
    p1=0
    for i in range(102):
        if i not in l:
            if abs(x-i)<a:
                a=abs(x-i)
                p1=i

    print(p1)
import sys
stdin = sys.stdin

ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))
nn = lambda: list(stdin.readline().split())
ns = lambda: stdin.readline().rstrip()

k = ni()
n = 50

a = k//n
b = k&n
c = n-1+x

ans = [str(c+n-b+1)]*b + [str(c-b)]*(n-b)

print(n)
print(''.join(ans))

### FIXED CODE ###

import sys
stdin = sys.stdin

ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))
nn = lambda: list(stdin.readline().split())
ns = lambda: stdin.readline().rstrip()

k = ni()
n = 50

a = k//n
b = k%n
c = n-1+a

ans = [str(c+n-b+1)]*b + [str(c-b)]*(n-b)

print(n)
print(' '.join(ans))
N,K = (int,input().split(" "))
if N%K == 0:
  print(0)
else:
  print(1)

### FIXED CODE ###

N,K = map(int,input().split(" "))
if N%K == 0:
  print(0)
else:
  print(1)
R=input()
print(R*3.141)

### FIXED CODE ###

print(3.1415*int(input())*2)
a=input()
b=a.split()

num=[]

x1=[1]*int(b[0])
x2=[0]*int(b[1])
x3=[-1]*int(b[2])

num[len(num):len(num)]=x1
num[len(num):len(num)]=x2
num[len(num):len(num)]=x3

k=int(b[3])
print(sum(num[0:k]))


### FIXED CODE ###


a = input()
b = input()

b1=list(b)
b1.pop(-1)
b2=""

for i in b1:
	b2 += i

if a == b2:
	print("Yes")

else:
	print("No")
M = int(imput())
D = int(imput())
D_array = list(map(int, str(D)))

ans = 0
for i in range(2,M+1):
  for d10 in range(2,int(D_array[0])+1):
    for d1 in range(2,10):
      if int(str(d10)+str(d1)) <= D:
        if int(d1)*int(d10) == i:
          ans += 1
print(ans)

### FIXED CODE ###

M,D = map(int,input().split())
D_array = list(map(int, str(D)))

ans = 0
for i in range(2,M+1):
  for d10 in range(2,int(D_array[0])+1):
    for d1 in range(2,10):
      if int(str(d10)+str(d1)) <= D:
        if int(d1)*int(d10) == i:
          ans += 1
print(ans)
N = int(input())
print(0.5 if N % 2 == 0 else ((N //2) + !)/ 2)

### FIXED CODE ###

N = int(input())
print(0.5 if N % 2 == 0 else -(-N // 2)/ N)
N=int(input())
F=[]
P=[]
for _ in range(N):
    F.append(list(map(int,input().split())))
for _ in range(N):
    P.append(list(map(int,input().split())))

m=2**10
gain=-10**8
for i in range(1,2**10):
    x=list(map(int,format(i,'b').zfill(10)))
    sumP=0
    for j in range(N):
        total=sum([a*b for a,b in zip(x,F[j])])
        sumP+=P[j][total]
    gain=max(gain,sumP)
print(gain)

### FIXED CODE ###

SS=list(input())
T=list(input())

SS.reverse()
T.reverse()

flag=0
for i in range(len(SS)-len(T)+1):
    if flag==0:
        for j in range(len(T)):
            if SS[i+j]==T[j] or SS[i+j]=='?':
                if j==len(T)-1:
                    flag=1
                    for k in range(len(T)):
                        SS[i+k]=T[k]
                    break
            else:
                break
            #if flag==1:
            #    break

ans=''
SS.reverse()
if flag==1:
    for i in range(len(SS)):
        if SS[i]=='?':
            SS[i]='a'
        ans+=SS[i]
else:
    ans='UNRESTORABLE'
print(ans)
repl(x*x*x)

### FIXED CODE ###

x = input()
ans = x**3
print ans
import sys

input = sys.stdin.readline

n_k = list(map(int, input().split()))
n = n_k[0]
k = n_k[1]
a = list(map(int, input().split()))
a_pos = list(filter(lambda v: v >= 0, a))
a_neg = list(filter(lambda v: v < 0, a))

a_pos.sort(reverse=True)
a_neg.sort()

mod = 10**9+7

ans = 1
if n == k:
    for a_i in a:
        ans = ans * a_i % mod
elif len(a_pos) == 0 and k % 2 == 1:
    for i in reversed(range(len(a_neg) - k, len(a_neg))):
        ans = ans * a_neg[i] % mod
else:
    i_p = 0
    i_n = 0
    i = 0
    while i < k:
        if i == k - 1 or i_n+1 >= len(a_neg) or a_pos[i_p] * a_pos[i_p+1] > a_neg[i_n] * a_neg[i_n+1]:
            ans = ans * a_pos[i_p] % mod
            i_p += 1
            i += 1
        else:
            ans = ans * a_neg[i_n] % mod * a_neg[i_n+1] % mod
            i_n += 2
            i += 2
print(ans)


### FIXED CODE ###

import sys

input = sys.stdin.readline

n_k = list(map(int, input().split()))
n = n_k[0]
k = n_k[1]
a = list(map(int, input().split()))
a_pos = list(filter(lambda v: v >= 0, a))
a_neg = list(filter(lambda v: v < 0, a))

a_pos.sort(reverse=True)
a_neg.sort()

mod = 10**9+7

ans = 1
if n == k:
    for a_i in a:
        ans = ans * a_i % mod
elif len(a_pos) == 0 and k % 2 == 1:
    for i in reversed(range(len(a_neg) - k, len(a_neg))):
        ans = ans * a_neg[i] % mod
else:
    i_p = 0
    i_n = 0
    i = 0
    while i < k:
        if i_p < len(a_pos) and (i == k - 1 or i_n+1 >= len(a_neg) or a_pos[i_p] * (a_pos[i_p+1] if i_p+1 < len(a_pos) else 1) > a_neg[i_n] * a_neg[i_n+1]):
            ans = ans * a_pos[i_p] % mod
            i_p += 1
            i += 1
        else:
            ans = ans * a_neg[i_n] % mod * a_neg[i_n+1] % mod
            i_n += 2
            i += 2
print(ans)
n,m = map(int, input().split());

A = []*m;
B = []*m;

for i in range(m):
  a, b = input().split();
  A[i] = int(a);
  B[i] = b;
  
#ACの数
AC_list = list(set(A));

AC_count = len(AC_list);

#WAの数
WA_count = 0;

for j in AC_list:
  indexes = [i for i, x in enumerate(A) if x == j];
  for k in indexes:
    if B[k] == "WA":
      WA_count += 1;
      continue;
    else:
      break;
      
print(AC_count, WA_count);


### FIXED CODE ###

n,m = map(int,input().split())
#ac,wa列を作成（pi問題がACならac[i]がTRUE、AC,WAに問わずwa[i]はwaの数）
ac, wa=[False]*n,[0]*n
for i in range(m):
  p,s = input().split()
  p=int(p)
  if s=='AC':
    ac[p-1]=True
  elif (s=='WA') and (ac[p-1]==False):
    wa[p-1]+=1

penalty, clear=0,0
for i,tf in enumerate(ac): #iはインデックス、tfはac[i]
  if tf:
    penalty += wa[i] #piがACされているとき、ペナルティ値を増やす
    clear += 1
print(clear, penalty)
#! /usr/bin/env python3
# -*- coding:utf-8 -*-

def discount(M, A):
    for _ in range(M):
        A.sort(reverse=True)
        A[0] = int(A[0]/2)
    return sum(A)

def main():
    N, M = map(int, input().split())
    A = map(int, input().split())
    discount(M, A)

if __name__ == '__main__':
    main()


### FIXED CODE ###

#! /usr/bin/env python3
# -*- coding:utf-8 -*-

def discount(M, A):
    from heapq import heappush, heappop
    hq = []
    for x in A:
        heappush(hq, (-x, x))
    for _ in range(M):
        _, price = heappop(hq)
        dprice = int(price/2)
        heappush(hq, (-dprice, dprice))
    return sum([x for _, x in hq])

def main():
    N, M = map(int, input().split())
    A = list(map(int, input().split()))
    print(discount(M, A))

if __name__ == '__main__':
    main()
def i1():
     return int(input())
    def i2():
     return [int(i) for i in input().split()]

    [a,b,c,d,e,f]=i2()
    g=[]
    for i in range(31):
        for j in range(31):
                    ttt=(a*i+b*j)*100
                    tk=min(ttt*e/100,f-ttt)
                    tt=(tk//d)*d+(tk%d//(d-c))*(d-c)
                    t=ttt+tt
                    if t>0 :
                        g.append([(100*tt)/t,t,tt])

    g.sort()
    print(int(g[-1][1]),int(g[-1][2]))

def i1():
 return int(input())
def i2():
 return [int(i) for i in input().split()]

[a,b,c,d,e,f]=i2()
g=[[0,100*a,0]]
for i in range(31):
    for j in range(31):
                ttt=(a*i+b*j)*100
                tk=min(ttt*e/100,f-ttt)
                tt=(tk//d)*d+(tk%d//(d-c))*(d-c)
                t=ttt+tt
                if t>0 :
                    g.append([(100*tt)/t,t,tt])

g.sort()
print(int(g[-1][1]),int(g[-1][2]))

### FIXED CODE ###

def i1():
 return int(input())
def i2():
 return [int(i) for i in input().split()]

[a,b,c,d,e,f]=i2()
w=[]
s=[]
for i in range(f+1):
    for j in range(f+1):
        t=(a*i+b*j)*100
        tt=c*i+d*j
        if t<=f:
           w.append(t)
        if tt<=f:
           s.append(tt)
a=0
g=[]
for i in w:
 for j in s:
     if 0<i+j<=f and j<=i*e/100:
        g.append([j*100/(i+j),i+j,j])
g.sort()
print(g[-1][1],g[-1][2])
#!/usr/bin/env python3
# -*- coding: utf-8 -*-

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

s = 0
b = 10 * 10 * 10 * 10 * 10 * 10 * 10 * 10 * 10 + 7
m = []
for i in range(1 - 1, N - 1):
    for j in range(i + 1 - 1, N + 1 - 1):
        s += A[i] ^ A[j]
        while s >= b:
            s -= b

print(s)


### FIXED CODE ###

#!/usr/bin/env python3
# -*- coding: utf-8 -*-

A1, A2, A3 = map(int, input().split())

print("bust" if A1 + A2 + A3 >= 22 else "win")
import sys
n,m = map(int,input().split())
l = list(map(int,input().split()))
l.sort(reverse=True)
sum1 = sum(l)/(4*m)
for i in range(m):
    if l[i] < sum1:
        print('No')
        sys.exit()
    else:
        l[i] == l[i+1]
print('Yes')

### FIXED CODE ###

import sys
n,m = map(int,input().split())
l = list(map(int,input().split()))
l.sort(reverse=True)
sum1 = sum(l)/(4*m)
for i in range(m):
    if l[i] < sum1:
        print('No')
        sys.exit()
print('Yes')
n = int(input())
if n == '1':
  print('Hello World')
else:
  print(map(+,map(int,input().split())))

### FIXED CODE ###

n = int(input())
if n == 1:
  print('Hello World')
else:
  print(sum([int(input()) for i in range(2)]))
n, m = map(int, input().split(' '))
a = list(map(int, input().split(' ')))
result = sum(a)
b_ = {}
for i in range(m):
    b, c = map(int, input().split(' '))
    b_[c] = b_.get(c, 0)
    b_[c] += b
if max(b_.keys()) < min(a):
    print(result)
else:
    a.sort()
    for j in range((len(a)-1)//2 + 2):
        t = max(b_.keys())
        if a[j] < t:
            a[j] = t
            b_[t] -= 1
        if b_[t] == 0:
            b_.pop(t)
        if b_ == {}:
            break
        t = max(b_.keys())        
        if a[n - j -1] < t:
            a[n-j-1] = t
            b_[t] -= 1
        if b_[t] == 0:
            b_.pop(t)
        if b_ == {}:
            break
    print(sum(a))

### FIXED CODE ###


n, m = map(int, input().split(' '))
a = list(map(int, input().split(' ')))
result = sum(a)
b_ = []
for i in range(m):
    b, c = map(int, input().split(' '))
    b_ += [(b,c)]
for i in range(n):
    b_ += [(1, a[i])]

from operator import itemgetter
b_.sort(key=itemgetter(1), reverse=True)

count = n
res = 0
for j, k in b_:
    if count > j:
        res += k * j
        count -= j
    elif count <= j:
        res += k * count
        break
print(res)
N, D, A = map(int, input().split())
XH = [list(map(int, input().split())) for _ in range(N)]
XH.sort()
X = [XH[i][0] for i in range(N)]
S = SegmentTree(N, 0, lambda x, y:x+y)
ans = 0
res = 0
from bisect import bisect
cnt = [0]*(N+1)
for i in range(N):
    x, h = XH[i]
    res-=cnt[i]
    h-=res
    if h<=0:
        continue
    n = ((h-1)//A+1)
    j = bisect(X, x+D*2+1)
    cnt[j]+=n*A
    res+= n*A
    ans+=n
print(ans)
    





### FIXED CODE ###


N, D, A = map(int, input().split())
XH = [list(map(int, input().split())) for _ in range(N)]
XH.sort()
X = [XH[i][0] for i in range(N)]
ans = 0
res = 0
from bisect import bisect_left
cnt = [0]*(N+1)
for i in range(N):
    x, h = XH[i]
    res-=cnt[i]
    h-=res
    if h<=0:
        continue
    n = ((h-1)//A+1)
    j = bisect_left(X, x+D*2+1)
    cnt[j]+=n*A
    res += n*A
    ans+=n
print(ans)
def main():
    n,m,r = map(int, input().split())
    dn = [[0] * m for _ in range(n)]
    
    for i in range(n):
        dn[i][:] = map(int, input().split())

    dn = np.array(dn)
    cost = []
    sh = 0
    inf = 10e8
    cost = inf
    k = np.zeros(m+1)
    
    def secom(j,k,cost):
        if j == n:
            
            if np.all(k>=r):
                print(k)
                cost = min(cost,k[0])
                return cost
            else:
                return cost
        
        cost1 = secom(j+1,k,cost)
        k += dn[j]
        cost2 = secom(j+1,k,cost)
        k -= dn[j]
        
        return min(cost1,cost2)
    
    
    cost = secom(0,k,cost)
    if cost == inf:
        print(-1)
    else:
        print(int(cost))
        
        

if __name__ == "__main__":
    main()


### FIXED CODE ###

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

C = list()
A = list()
for i in range(N):
	temp = list(map(int,input().split()))
	C.append(temp[0])
	A.append(temp[1:])	


MAX = 100000000000	

def func(cost,a,i):
	if min(a) >= X:
		return cost
	elif i == N:
		return MAX
	total_A = [x+y for (x,y) in zip(a,A[i])]
    
	return min(func(cost + C[i],total_A,i+1),func(cost,a,i+1))
	
ans = func(0,[0]*M,0)

if ans == MAX:
	print(-1)
else:
	print(ans)
a, b = map(int, input().split())
A = str(bin(a))[2:]
if A[-1] == '0':
    if (b-a+1)%2 == 0:
        mae = '0'
    else:
        mae = str(bin(int(A[:-1], 2)+int((b-a)/2)))[2:]
    if (b-a+1)%4 == 0 or (b-a+1)%4 == 3:
        print(int(mae+'0', 2))
    else:
        print(int(mae+'1', 2))
else:
    if (b-a+1)%2 == 0:
        mae = '0'
    else:
        mae = A[:-1]
    if (b-a+1)%4 == 2 or (b-a+1)%4 == 3:
        print(int(mae+'0', 2))
    else:
        print(int(mae+'1', 2))


### FIXED CODE ###

a, b = map(int, input().split())
A = str(bin(a))[2:]
B = str(bin(b))[2:]
if A[-1] == '0':
    if (b-a+1)%2 == 0:
        mae = '0'
    else:
        if a <= 1:
            c = '0'
        else:
            c = A[:-1]
        mae = str(bin(int(c, 2)+int((b-a)/2)))[2:]
    if (b-a+1)%4 == 0 or (b-a+1)%4 == 1:
        print(int(mae+'0', 2))
    else:
        print(int(mae+'1', 2))
else:
    if (b-a+1)%2 == 0:
        if a <= 1:
            c = '0'
        else:
            c = A[:-1]
        if b <= 1:
            d = '0'
        else:
            d = B[:-1]

        mae = str(bin(int(c, 2)^int(d, 2)))[2:]
    else:
        mae = A[:-1]
    if (b-a+1)%4 == 0 or (b-a+1)%4 == 3:
        print(int(mae+'0', 2))
    else:
        print(int(mae+'1', 2))
"""

https://atcoder.jp/contests/abc173/tasks/abc173_e

クソだけどやろう

正負・0を分割

0がある場合は、最大を0に更新
0がN-K個より多い場合は即終了

残りの場合は、0を取らなくても構成できる場合のみ


"""

import sys
N,K = map(int,input().split())
A = list(map(int,input().split()))

pl = []
mi = []
znum = 0

if K == 1:
    print (max(A))
    sys.exit()

for i in A:
    if i > 0:
        pl.append(i)
    elif i == 0:
        znum += 1
    else:
        mi.append(i)

ans = float("-inf")
if znum > 0:
    ans = 0

#0にならざるを得ない場合を処理
if znum > N-K:
    print (ans)
    sys.exit()

#答えが負になる場合も処理する
#大きいほうからかけていけばいい
#N個の場合 or 正がない場合は負になりえない
mod = 10**9+7
pl.sort()
mi.sort()

if K == N:
    ans = 1
    for i in range(N):
        ans *= A[i]
        ans %= mod
    print (ans)
    sys.exit()

if K % 2 == 1 and len(pl) == 0:
    if znum > 0:
        ans = 0
    else:
        ans = 1
    mi.reverse()
    for i in range(K):
        ans *= mi[i]
        ans %= mod
    print (ans)
    sys.exit()

#まず、2個づつセットにすることを考える
#正負でセットにしていって、あまり同士も合成する

if K % 2 == 1:
    K -= 1
    ans = pl[-1]
    del pl[-1]
else:
    ans = 1

pl2 = []
pl.reverse()
pl.append(0)
pl2.append(0)
for i in range(0,len(pl),2):
    pl2.append(pl[i] * pl[i+1])
for j in range(0,len(mi),2):
    pl2.append(mi[i] * mi[i+1])

pl2.sort()
pl2.reverse()
for i in range(K//2):
    ans *= pl2[i]
    ans %= mod
print (ans)


### FIXED CODE ###


"""

https://atcoder.jp/contests/abc173/tasks/abc173_e

クソだけどやろう

正負・0を分割

0がある場合は、最大を0に更新
0がN-K個より多い場合は即終了

残りの場合は、0を取らなくても構成できる場合のみ


"""

import sys
N,K = map(int,input().split())
A = list(map(int,input().split()))

pl = []
mi = []
znum = 0

if K == 1:
    print (max(A))
    sys.exit()

for i in A:
    if i > 0:
        pl.append(i)
    elif i == 0:
        znum += 1
    else:
        mi.append(i)

ans = float("-inf")
if znum > 0:
    ans = 0

#0にならざるを得ない場合を処理
if znum > N-K:
    print (ans)
    sys.exit()

#答えが負になる場合も処理する
#大きいほうからかけていけばいい
#N個の場合 or 正がない場合は負になりえない
mod = 10**9+7
pl.sort()
mi.sort()

if K == N:
    ans = 1
    for i in range(N):
        ans *= A[i]
        ans %= mod
    print (ans)
    sys.exit()

if K % 2 == 1 and len(pl) == 0:
    if znum > 0:
        ans = 0
    else:
        ans = 1
    mi.reverse()
    for i in range(K):
        ans *= mi[i]
        ans %= mod
    print (ans)
    sys.exit()

#まず、2個づつセットにすることを考える
#正負でセットにしていって、あまり同士も合成する

if K % 2 == 1:
    K -= 1
    ans = pl[-1]
    del pl[-1]
else:
    ans = 1

pl2 = []
pl.reverse()
if len(pl) % 2 == 1:
    pl.append(0)
if len(mi) % 2 == 1:
    mi.append(0)
for i in range(0,len(pl),2):
    pl2.append(pl[i] * pl[i+1])
for i in range(0,len(mi),2):
    pl2.append(mi[i] * mi[i+1])


pl2.sort()
pl2.reverse()
for i in range(K//2):
    ans *= pl2[i]
    ans %= mod
print (ans)
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())

l = [a, b, c, d, e]
d = list()

for i, x in enumerate(l[:-1]):
    l2 = l[i+1:]
    for y in l2:
        d.append(y-x)

if max(d) <= k:
    print('Yay!')
else:
    print(':(')

### FIXED CODE ###

A = input()
B = input()
C = input()
D = input()
E = input()


l = [A, B, C, D, E]
l2 = list()

# check min 1 keta

m = -1

for x in l:
    t = int(x) % 10
    if t == 0:
        l2.append(int(x))
    else:
        l2.append((int(x) + 10) // 10 * 10)

l3 = [int(x) % 10 for x in l]
l3 = [x for x in l3 if x != 0]

if len(l3) == 0:
    print(sum(l2))
else:
    print(sum(l2) - 10 + min(l3))
n,k=map(int,input().split())
h=list(map(int,input().split()))
dp=[10**9]*n

dp[0]=0
for i in range(1,n):
    for j in range(min(0,i-k),i):
        dp[i]=min(dp[i],dp[j]+abs(h[i]-h[j]))
    
print(dp[n-1])

### FIXED CODE ###

n,k=map(int,input().split())
h=list(map(int,input().split()))
dp=[10**9]*n

dp[0]=0
for i in range(1,n):
    for j in range(1,min(k+1,i+1)):
        dp[i]=min(dp[i],dp[i-j]+abs(h[i]-h[i-j]))
    
print(dp[n-1])
n = input()
n.sort()
if n[0] == "a" and n[1] == "b" and n[2] == "c":
    print("Yes")
else:
    print("No")

### FIXED CODE ###

n = input()
if n.count("a") == 1 and n.count("b") == 1 and n.count ("c") == 1:
    print("Yes")
else:
    print("No")
h, w = map(int, input().split())
s = ['.'*(h+2)] + ['.' + input() + '.' for i in range(h)] + ['.'*(h+2)]
d = [[1, 0], [0, 1], [-1, 0], [0, -1]]

ans = 0
for i in range(1, h+1):
    for j in range(1, w+1):
        if s[i][j] == '.':
            continue
        c = 0
        for k in range(4):
            if s[i+d[k][0]][j+d[k][1]] == "#":
                c += 1
        if c == 0:
            ans = -1

if ans == -1:
    print("No")
else:
    print("Yes")


### FIXED CODE ###

h, w = map(int, input().split())
s = ['.'*(w+2)] + ['.' + input() + '.' for i in range(h)] + ['.'*(w+2)]
d = [[1, 0], [0, 1], [-1, 0], [0, -1]]

ans = 0
for i in range(1, h+1):
    for j in range(1, w+1):
        if s[i][j] == '.':
            continue
        c = 0
        for k in range(4):
            if s[i+d[k][0]][j+d[k][1]] == "#":
                c += 1
        if c == 0:
            ans = -1

if ans == -1:
    print("No")
else:
    print("Yes")
def ten_to_n(X, n):
    i = int(X / n)
    s = str(X % n)
    if (i):
        return Base_10_to_n(i, n) + s
    return s

def solve():
    N, M = map(int, input().split())
    n = Base_10_to_n(N, M)
    return len(n)
 
print(solve())

### FIXED CODE ###

def Base_10_to_n(X, n):
    if (int(X/n)):
        return Base_10_to_n(int(X/n), n)+str(X%n)
    return str(X%n)

def solve():
    N, M = map(int, input().split())
    n = Base_10_to_n(N, M)
    return len(n)

print(solve())
def main():
    n, m = map(int, input().split())
    inf = 10**9 #この10億は何に使う？->とにかくデカい数字。
    bit_bp = [inf for _ in range(2**(n))] #10億を2**n個並べる配列を作る。n=12 => 4096個
    bit_dp[0] = 0

    for i in range(m):
        a, b = map(int, input().split())
        c = list(map(int, input().split()))#鍵1個につきa,b,c1~cbを決める
        bit_n = 0
        for i in c:
            bit_n |= 1 << i - 1 #ここで何番目をあけられるのかをbit_nで定義する。1と3ならbit_n=(5)101、2と3なら110(6)
        for i in range(2**n):
            if bit_dp[i|bit_n] > bit_dp[i] + a: #
                bit_dp[i|bit_n] = bit_dp[i] + a

    if bit_dp[-1] >= inf:
        print(-1)
    else:
        print(bit_dp[-1])
                
if __name__ == "__main__":
    main()

### FIXED CODE ###

#E https://atcoder.jp/contests/abc142/submissions/7853616
def main():
    n, m = map(int, input().split())
    inf = 10**9 #この10億は何に使う？->とにかくデカい数字。
    bit_dp = [inf for _ in range(2**(n))] #10億を2**n個並べる配列を作る。n=12 => 4096個
    bit_dp[0] = 0
    for i in range(m):
        a, b = map(int, input().split())
        c = list(map(int, input().split()))#鍵1個につきa,b,c1~cbを決める
        bit_n = 0
        for i in c:
            bit_n |= 1 << i - 1 #ここで何番目をあけられるのかをbit_nで定義する。1と3ならbit_n=(5)101、2と3なら110(6)
        for i in range(2**n):
            if bit_dp[i|bit_n] > bit_dp[i] + a:
                bit_dp[i|bit_n] = bit_dp[i] + a
    if bit_dp[-1] >= inf:
        print(-1)
    else:
        print(bit_dp[-1])
                
if __name__ == "__main__":
    main()
n = int(input())
if n ==1:
    print('Hello world')
if n ==2:
    a,b = map(int,input().split())
    print(a+b)
    

### FIXED CODE ###

n = int(input())
if n ==1:
    print('Hello World')
if n ==2:
    a = int(input())
    b = int(input())
    ans = a+b
    print(ans)
n, k = map(int, input().split())
x = list(map(int, input().split()))

ans = []
for i in range(n - k + 1):
    left = x[i]
    right = x[i + k - 1]
    elif abs(left) > abs(right):
        ans.append(abs(right) + abs(left - right))
    else:
        ans.append(abs(left) + abs(right - left))

print(min(ans))

### FIXED CODE ###

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

ans = []
for i in range(n - k + 1):
    left = x[i]
    right = x[i + k - 1]
    ans.append(min(abs(left) + abs(right - left),
                   abs(right) + abs(left - right)))

print(min(ans))
import sys
n,m=list(map(int,input().split()))
ans=[-1 for i in range(n)]

for i in range(m):
  s,c=list(map(int,input().split()))
  if n!=1 and s==1 and c==0:
    print(-1)
    sys.exit()
  if ans[s-1]==-1 or ans[s-1]==c:
    ans[s-1]=c
  else:
    print(-1)
    sys.exit()

    
if n==1 and ans[0]==0　or ans[0]==-1
  print(0)
  sys.exit()
if ans[0]==-1:
  ans[0]=1
for i in range(1,n):
  if ans[i]==-1:
    ans[i]=0
ans=map(str, ans)
print("".join(ans))

  

### FIXED CODE ###

import sys
n,m=list(map(int,input().split()))
ans=[-1 for i in range(n)]

for i in range(m):
  s,c=list(map(int,input().split()))
  if n!=1 and s==1 and c==0:
    print(-1)
    sys.exit()
  if ans[s-1]==-1 or ans[s-1]==c:
    ans[s-1]=c
  else:
    print(-1)
    sys.exit()

    
if n==1 and (ans[0]==0 or ans[0]==-1):
  print(0)
  sys.exit()
if ans[0]==-1:
  ans[0]=1
for i in range(1,n):
  if ans[i]==-1:
    ans[i]=0
ans=map(str, ans)
print("".join(ans))
#-*-coding:utf-8-*-
import sys
input=sys.stdin.readline
import numpy as np

def main():
    numbers=[]
    a,b,k = map(int,input().split())
    numbers=np.arange(a,b+1)
    A=numbers[:k]
    B=numbers[-k:]
    if set(A)==set(B):
        answers=A
    else:
        A = set(A)
        B = set(B)
        answers = A|B
    for n in sorted(answers):
        print(n)

if __name__=="__main__":
    main()

### FIXED CODE ###

#-*-coding:utf-8-*-
import sys
input=sys.stdin.readline
import numpy as np

def main2():
    A,B,K=map(int,input().split())
    if A+K-1>=B-K+1:
        for i in range(A,B+1):
            print(i)
    else:
        for i in range(A,A+K):
            print(i)
        for i in range(B-K+1,B+1):
            print(i)

def main():
    numbers=[]
    a,b,k = map(int,input().split())
    numbers=np.arange(a,b+1)
    A=set(numbers[:k])
    B=set(numbers[-k:])
    answers = A|B
    
    for i in sorted(answers):
        print(i)

if __name__=="__main__":
    main2()
s,t=map(int,input().split())
print(t+s)

### FIXED CODE ###

左,右=map(str,input().split())
print(右+左)