CodeEff/ECCO huggingface dataset:
# Original solution
import math
X = int(eval(input()))

def is_prime(x):
    a = int(math.sqrt(X)) + 1
    for i in range(2,a):
        if x % i == 0:
            return False
    return True

for j in range(X,X+100):
    if is_prime(j):
        ans = j    
        break
print(ans)

# Optimized solution
import math
X = int(eval(input()))

def is_prime(x):
    a = int(math.sqrt(X)) + 1#ある数が素数かどうかはO(√A)で判定できる
    for i in range(2,a):
        if x % i == 0:
            return False
    return True#xは素数

for j in range(X,10**5+4):
    if is_prime(j):
        ans = j    
        break
print(ans)
# Original solution
from bisect import bisect_left, bisect_right

def get_primes(n):
    if not isinstance(n, int):
        raise TypeError('n is int-type.')
    if n < 2:
        raise ValueError('n is more than 2')
    
    from math import sqrt 
    def _sieve_of_eratosthenes(n):
        primes = []
        limit = sqrt(n)
        data = [i + 1 for i in range(1, n)]
        while True:
            p = data[0]
            if limit <= p:
                return primes + data
            primes.append(p)
            data = [e for e in data if e % p != 0]
    return _sieve_of_eratosthenes(n)

primes = get_primes(10**5 + 3)
print((primes[bisect_left(primes, int(eval(input())))]))

# Optimized solution
from bisect import bisect_left

def get_primes(n):
    if not isinstance(n, int):
        raise TypeError('n is int-type.')
    if n < 2:
        raise ValueError('n is more than 2')
    
    from math import sqrt 
    def _sieve_of_eratosthenes(n):
        primes = []
        limit = sqrt(n)
        data = [i + 1 for i in range(1, n)]
        while True:
            p = data[0]
            if limit <= p:
                return primes + data
            primes.append(p)
            data = [e for e in data if e % p != 0]
    return _sieve_of_eratosthenes(n)

primes = get_primes(10**5 + 3)
print((primes[bisect_left(primes, int(eval(input())))]))
# Original solution
#!/usr/bin/env python3
from collections import defaultdict,deque
from heapq import heappush, heappop
from bisect import bisect_left, bisect_right
import sys, random, itertools, math
sys.setrecursionlimit(10**5)
input = sys.stdin.readline
sqrt = math.sqrt
def LI(): return list(map(int, input().split()))
def LF(): return list(map(float, input().split()))
def LI_(): return list([int(x)-1 for x in input().split()])
def II(): return int(eval(input()))
def IF(): return float(eval(input()))
def LS(): return list(map(list, input().split()))
def S(): return list(input().rstrip())
def IR(n): return [II() for _ in range(n)]
def LIR(n): return [LI() for _ in range(n)]
def FR(n): return [IF() for _ in range(n)]
def LFR(n): return [LI() for _ in range(n)]
def LIR_(n): return [LI_() for _ in range(n)]
def SR(n): return [S() for _ in range(n)]
def LSR(n): return [LS() for _ in range(n)]
mod = 1000000007
inf = float('INF')


def primes(n):
    """ 
    Input n>=6, Returns a list of primes, 2 <= p < n 
    6以上の数であれば p (素数) <= n のlistを返す 
    :param int n:
    :rytpe list:
    """
    n, correction = n-n%6+6, 2-(n%6>1)
    sieve = [True] * (n//3)
    for i in range(1,int(n**0.5)//3+1):
        if sieve[i]:
            k=3*i+1|1
            sieve[      k*k//3      ::2*k] = [False] * ((n//6-k*k//6-1)//k+1)
            sieve[k*(k-2*(i&1)+4)//3::2*k] = [False] * ((n//6-k*(k-2*(i&1)+4)//6-1)//k+1)
    return [2,3] + [3*i+1|1 for i in range(1,n//3-correction) if sieve[i]]

#solve
def solve():
    x = II()
    p = primes(10 ** 6)
    print((p[bisect_left(p, x)]))
    return


#main
if __name__ == '__main__':
    solve()


# Optimized solution
n = int(eval(input()))
def f(x):
    for k in range(2, int(x**0.5) + 1):
        if x % k != 0:
            continue
        return False
    return True
i = n
while 1:
    if f(i):
        print(i)
        break
    i += 1
# Original solution
x = int(eval(input()))
y = x + 100
is_prime = [False] * 2 + [True for _ in range(2, y+1)]
prime = []
for i in range(2, y+1):
	for j in range(i*2, y+1, i):
		is_prime[j] = False
for i in range(y+1):
	if is_prime[i]:
		prime.append(i)
for i in range(len(prime)):
  if prime[i] >= x:
    print((prime[i]))
    break
  else:
    continue

# Optimized solution
x = int(eval(input()))
while True:
  x_sqrt = int(x ** 0.5)
  for i in range(2, x_sqrt+1):
    if x % i == 0:
      break
  else:
    print(x)
    break
  x += 1
# Original solution
x = int(eval(input()))

for i in range(x,10**5+100):
    flg = 'so'
    for j in range(2,x):
        
        if i % j == 0:
            flg = 'no'
   
    if flg == 'so':
        print(i)
        exit()

# Optimized solution
x = int(eval(input()))

for i in range(x,10**5+100):
    flg = 'so'
    for j in range(2,x):
        
        if i % j == 0:
            flg = 'no'
            break
   
    if flg == 'so':
        print(i)
        exit()
# Original solution
import math
X = int(eval(input()))


def get_primenumber(number):
    prime_list = []
    # 2からnumberまでの数字をsearch_listに入れる
    search_list = list(range(2, number+1))
    while True:
    # search_listの先頭の値が√nの値を超えたら処理終了
        if search_list[0] > math.sqrt(number):
            # prime_listにsearch_listを結合
            prime_list.extend(search_list)
            break
        else:
            # search_listの先頭をprime_listに入れる
            head_num = search_list[0]
            prime_list.append(head_num)
            # search_listの先頭をpopする
            search_list.pop(0)
            # head_numの倍数を取り除く
            search_list = [num for num in search_list if num % head_num != 0]
    return prime_list

prime_list = get_primenumber(100000)

left = 0
right = len(prime_list)-1

if X == 2:
    print((int(2)))
elif X > 99991:
    print((int(100003)))
else:
    while left <= right:
        mid = (left+right) // 2
        if prime_list[mid] == X:
            ans = prime_list[mid]
            break
        elif prime_list[mid] > X:
            if prime_list[mid-1] < X:
                ans = prime_list[mid]
                break
            else:
                right = mid - 1
        else:
            if prime_list[mid+1] > X:
                ans = prime_list[mid+1]
                break
            else:
                left = mid + 1

    print((int(ans)))

# Optimized solution
x = int(eval(input()))

while True:
    i = 2
    ok = True
    while i * i <= x:
        if x % i == 0:
            ok = False
            break
        i += 1
    if ok:
        print(x)
        break
    x += 1
# Original solution
X = int(eval(input()))

while True:
    flg=True
    for i in range(2, X):
        if X%i!=0:
            continue
        flg=False
        break
    if flg:
        print(X)
        break
    else:
        X+=1
        continue

# Optimized solution
import math
X = int(eval(input()))
Y = int(math.sqrt(X))
while True:
    flg=True
    for i in range(2, Y):
        if X%i!=0:
            continue
        flg=False
        break
    if flg:
        print(X)
        break
    else:
        X+=1
        continue
# Original solution
#!/usr/bin/env python3
import math
n = int(eval(input()))
def eratosthenes(n):
    prime = [2]
    i = 2
    while prime[-1] < n:
        i += 1
        prime_bit = 0
        for div in prime:
            if i % div == 0: 
                break
            if div == prime[-1]: prime_bit = 1
        if prime_bit: prime.append(i)
        """for j in range(2,math.ceil(i**1/2)+1): #２だけ特別扱いしないといけない
            if i % j == 0: break
            if j == math.ceil(i**1/2): 
                prime.append(i)"""
    return prime
prime = eratosthenes(n)
print((prime[-1]))

# Optimized solution
#!/usr/bin/env python3
import math
n = int(eval(input()))
def is_prime(n):
    for i in range(2,math.ceil(n**1/2)+1):
        if n % i == 0:
            return False
    return True    
i = n
while True:
    if is_prime(i): break
    i += 1
print(i)
# Original solution
X=int(eval(input()))
flag = True
if X == 2:
    print(X)
else:
    while flag:
        i = 2
        while i<X:
            if X%i == 0:
                break
            if i == X-1:
                print(X)
                flag = False
                break
            i = i+1
        X = X+1

# Optimized solution
X=int(eval(input()))
def is_prime(q,k=100):
    q = abs(q)
    if q == 2: return True
    if q < 2 or q&1 == 0: return False
    for i in range(3,k):
        x,y = q,i
        while y:
            x, y =  y, x % y
        if x != 1: continue
        if pow(i, q-1, q) != 1:
            return False
    return True
flag=False
while(flag==False):
    if is_prime(X):
        print(X)
        flag=True
        break
    X+=1
# Original solution
# import numpy as np
import math
import sys
input = sys.stdin.readline

X = int(eval(input()))

if X == 2:
    print(X)
    sys.exit()

def segment_sieve(a,b):
    ass = []
    is_prime_small = [True] * (int(b**0.5)+1)
    is_prime = [True] * (b-a)
    for i in range(2,int(b**0.5)):
        if is_prime_small[i]:
            j = 2*i
            while j**2 < b:
                is_prime_small[j] = False
                j += i
            j = max(2*i,((a+i-1)//i)*i)
            while j < b:
                is_prime[j-a] = False
                j += i
    for i in range(len(is_prime)):
        if is_prime[i]:
            ass.append(a+i)
    if ass[0] == 1:
        del ass[0]
    return ass

list = segment_sieve(X,100004)
res = list[0]

print(res)


# Optimized solution
# import numpy as np
import math
import sys
input = sys.stdin.readline

X = int(eval(input()))

def is_prime(x):
    if x <= 1:
        return False
    for i in range(2,int(math.sqrt(x))+1):
        if x % i == 0:
            return False
    return True

while not is_prime(X):
    X += 1

print(X)
# Original solution
X = int(eval(input()))
import math 
def get_prime(n):
    
    if n <=1:
        return []
    prime = [2]
    limit = int(math.sqrt(n))
    
    # 奇数のリストを作成
    data = [i+1 for i in range(2,n,2)]
    while limit > data[0]:
        prime.append(data[0])
        data = [j for j in data if j % data[0] !=0]
    return prime + data
for x in get_prime(2*X):
    if x >=X:
        print(x)
        break



# Optimized solution
X = int(eval(input()))
def is_prime(n):
    if n <= 1:
        return False
    
    for i in range(2,int(n**0.5)+1):
        if n % i ==0:
            return False
    return True

for i in range(X,(X*2)+100,):
    if is_prime(i):
        print(i)
        break
# Original solution
X = int(eval(input()))
def is_prime(n):
    if n <= 1:
        return False
    
    for i in range(2,int(n**0.5)+1):
        if n % i ==0:
            return False
    return True

for i in range(X,(X*2)+100,):
    if is_prime(i):
        print(i)
        break
            

# Optimized solution
X = int(eval(input()))
def is_prime(n):
    if n <= 1:
        return False
    
    for i in range(2,int(n**0.5)+1):
        if n % i ==0:
            return False
    return True
while not is_prime(X):
        X+=1
print(X)
# Original solution
import math
import sys
x = int(eval(input()))
flg = 0

if x == 2:
  print(x)
  sys.exit()

for i in range(x,100005):
  flg = 0
  for j in range(2,int(math.sqrt(i))+1):
    if i%j == 0:
      flg = 1
    if flg == 0 and j == int(math.sqrt(i)):
      print(i)
      sys.exit()
    continue
      

# Optimized solution
import sys
import math
x=int(eval(input()))

while True:
  for i in range(2,int(math.sqrt(x))):
    if x%i==0:
      break
  else:
    print(x)
    break
  x+=1
# Original solution
X = int(eval(input()))
for i in range(X, 100005):
  for j in range(2,i):
    if i%j == 0:
      break
  else:
    print(i)
    quit()

# Optimized solution
import math
X = int(eval(input()))
def isPrime(n):
  if n == 1:
    return False
  max = math.ceil(math.sqrt(n))
  for i in range(2,max):
    if n % i == 0:
      return False
  return True

while(True):
  if isPrime(X):
    print(X)
    quit()
  else:
    X = X+1
# Original solution
N = int(eval(input()))

ans = -1
x = N
while(ans == -1):
    if all([x % i != 0 for i in range(2, x)]):
        ans = x
    else:
        x += 1
print(ans)

# Optimized solution
x=int(eval(input()))
f=0
if x == 2:
	print((2))
else:
	for i in range(x,10**6):
		for j in range(2,i//2+2):
			if i%j == 0:
				break
		else:
			f=i
			break
	print(f)
# Original solution
x=int(eval(input()))
f=0
if x == 2:
	print((2))
else:
	for i in range(x,10**6):
		for j in range(2,i//2+2):
			if i%j == 0:
				break
		else:
			f=i
			break
	print(f)


# Optimized solution
from math import sqrt
n=int(eval(input()))
def is_prime(n):
    if n<2:
        return False
    for k in range(2,int(sqrt(n))+1):
        if n%k==0:
            return False
    return True
while not is_prime(n):
    n+=1
print(n)
# Original solution
def eratosthenes(n: int) -> list:
    is_prime = [True] * (n + 1)
    is_prime[0] = is_prime[1] = False
    for i in range(2, n // 2 + 1):
        if is_prime[i]:
            for j in range(2, n // i + 1):
                is_prime[i * j] = False
    return is_prime


x = int(eval(input()))
is_prime = eratosthenes(x * 2 + 100)
ans = x
while not is_prime[ans]:
    ans += 1
print(ans)


# Optimized solution
def is_prime(n):
    if n <= 1:
        return False
    elif n == 2:
        return True
    elif n % 2 == 0:
        return False
    for i in range(3, n, 2):
        if i * i > n:
            break
        if n % i == 0:
            return False
    return True


x = int(eval(input()))
while not is_prime(x):
    x += 1
print(x)
# Original solution
def genP():
	yield 2
	yield 3
	c=6
	while 1:
		yield c-1
		yield c+1
		c+=6
def sosu(n):
	if n in [2,3,5]:
		return True
	l=int(n**0.5)+1
	p=genP()
	for i in p:
		if i>l:
			return True
			break
		elif n%i==0:
			return False
			break



def resolve():
	x=int(eval(input()))
	while 1:
		if sosu(x):
			print(x)
			break
		else:
			x+=1

resolve()

# Optimized solution
def sosu(p):
	if p==2:
		return True
	l=int(p**0.5)+1
	for i in range(2,l+1):
		if p%i==0:
			return False
	return True
x=int(eval(input()))
x+=1 if x!=2 and x%2==0 else 0
while sosu(x)==False:
	x+=2
print(x)
# Original solution
x = int(eval(input()))
p = [True] * 100004
p[0] = False
p[1] = False
for i in range(int(100003 ** 0.5)):
    if p[i] == False:
        continue
    for j in range(2, 100003 // i + 1):
        p[i * j] = False
for i in range(x, 100004):
    if p[i] == True:
        print(i)
        break

# Optimized solution
x = int(eval(input()))
for i in range(x, 100003 + 1):
    for j in range(2, i):
        if i % j == 0:
            break
    else:
        print(i)
        break
# Original solution
X = int(eval(input()))

count = 0

for i in range(2, X+1, 1):
    if X % i == 0:
        count += 1
    
if count == 1:
    print(X)
else:
    while True:
        count = 0
        X += 1
        for i in range(2, X+1, 1):
            if X % i == 0:
                count += 1
        if count == 1:
            print(X)
            break

# Optimized solution
x = int(eval(input()))
p = x - 1
prime = False

if x == 2:
    print((2))
else:
    while prime == False:
        p += 1
        prime = True
        
        for i in range(2, p - 1):
            if p % i == 0:
                prime = False
                break
            
    print(p)
# Original solution
import sys
import math
input = sys.stdin.readline

def multiples(n):
    for i in range(3,100003):
        yield i*n
        if i*n > 100003:
            break

def sosuu(x):
    if x == 2 : return 2
    d = set()
    end = math.ceil(math.sqrt(x))
    d = d.union(multiples(2))
    for i in range(3,end,2):
        if i not in d:
            d = d.union(set(multiples(i)))
    
    i = x if x % 2 != 0 else x+1
    while True:
        if i not in d:
            return i
        i += 2

def main():
    x = int(eval(input()))
    print((sosuu(x)))

if __name__ == "__main__":
    main()

# Optimized solution
import sys
import math
input = sys.stdin.readline

def is_prime(x):
    if x <= 1: 
        return False
    for i in range(2,math.ceil(x**0.5)):
        if x%i==0: 
            return False
    return True
def main():
    x = int(eval(input()))
    p = x
    while not is_prime(p):
        p += 1
    print(p)

if __name__ == "__main__":
    main()
# Original solution
n = int(eval(input()))

while(True):
    flag = True
    for i in range(2, n):
        if n % i == 0:
            flag = False
            break
    if flag:
        break
    n += 1

print(n)


# Optimized solution
n = int(eval(input()))

def is_prime(n):
    flag = True
    for i in range(2, n):
        if n % i == 0:
            flag = False
            break
    return flag

while(not is_prime(n)):
    n += 1

print(n)
# Original solution
import math
from itertools import product
x = int(eval(input()))
limit = 10**5
sosu = -1
flag = 1
i = x
while True:
  for j in range(2, int(math.sqrt(i))+1):
    if (i%j)==0:
      flag = 0
      break
  if flag:
    sosu = i
    break
  else:
    i += 1
    flag = 1
print(sosu)

# Optimized solution
import math
x = int(eval(input()))
limit = 10**5
i = x
while True:
  for j in range(2, int(math.sqrt(i))+1):
    if (i%j)==0:
      break
  else:
    # すべてのjで割り切れなかった場合
    print(i)
    break
  i += 1
# Original solution
import sys
sys.setrecursionlimit(10 ** 6)
# input = sys.stdin.readline    ####
def int1(x): return int(x) - 1
def II(): return int(eval(input()))

def MI(): return list(map(int, input().split()))
def MI1(): return list(map(int1, input().split()))

def LI(): return list(map(int, input().split()))
def LI1(): return list(map(int1, input().split()))
def LLI(rows_number): return [LI() for _ in range(rows_number)]

def SI(): return input().split()

def printlist(lst, k='\n'): print((k.join(list(map(str, lst)))))
INF = float('inf')

from math import ceil, floor, log2
from collections import deque
from itertools import combinations as comb, combinations_with_replacement as comb_w, accumulate, product
from heapq import heapify, heappop, heappush


def solve():
    X = II()

    while 1:
        for i in range(2, X):
            if X % i == 0:
                break
        else:
            print(X)
            return

        X += 1



if __name__ == '__main__':
    solve()


# Optimized solution
import sys
sys.setrecursionlimit(10 ** 6)
# input = sys.stdin.readline    ####
def int1(x): return int(x) - 1
def II(): return int(eval(input()))

def MI(): return list(map(int, input().split()))
def MI1(): return list(map(int1, input().split()))

def LI(): return list(map(int, input().split()))
def LI1(): return list(map(int1, input().split()))
def LLI(rows_number): return [LI() for _ in range(rows_number)]

def SI(): return input().split()

def printlist(lst, k='\n'): print((k.join(list(map(str, lst)))))
INF = float('inf')

from math import ceil, floor, log2
from collections import deque
from itertools import combinations as comb, combinations_with_replacement as comb_w, accumulate, product
from heapq import heapify, heappop, heappush


def solve():
    X = II()

    while 1:
        for i in range(2, int(pow(X, 0.5))+1):
            if X % i == 0:
                break
        else:
            print(X)
            return

        X += 1



if __name__ == '__main__':
    solve()
# Original solution
import sys
sys.setrecursionlimit(10 ** 6)
# input = sys.stdin.readline    ####
def int1(x): return int(x) - 1
def II(): return int(eval(input()))

def MI(): return list(map(int, input().split()))
def MI1(): return list(map(int1, input().split()))

def LI(): return list(map(int, input().split()))
def LI1(): return list(map(int1, input().split()))
def LLI(rows_number): return [LI() for _ in range(rows_number)]

def SI(): return input().split()

def printlist(lst, k='\n'): print((k.join(list(map(str, lst)))))
INF = float('inf')

from math import ceil, floor, log2, sqrt
from collections import deque
from itertools import combinations as comb, combinations_with_replacement as comb_w, accumulate, product
from heapq import heapify, heappop, heappush

def is_prime(n):
    for i in range(2, int(sqrt(n))+1):
        if n % i == 0:
            return False

    return True


def solve():
    X = II()

    while 1:
        if is_prime(X):
            print(X)
            return

        X += 1



if __name__ == '__main__':
    solve()


# Optimized solution
# import sys
# sys.setrecursionlimit(10 ** 6)
# # input = sys.stdin.readline    ####
# def int1(x): return int(x) - 1
def II(): return int(eval(input()))

# def MI(): return map(int, input().split())
# def MI1(): return map(int1, input().split())
#
# def LI(): return list(map(int, input().split()))
# def LI1(): return list(map(int1, input().split()))
# def LLI(rows_number): return [LI() for _ in range(rows_number)]
#
# def SI(): return input().split()
#
# def printlist(lst, k='\n'): print(k.join(list(map(str, lst))))
# INF = float('inf')
#
# from math import ceil, floor, log2, sqrt
# from collections import deque
# from itertools import combinations as comb, combinations_with_replacement as comb_w, accumulate, product
# from heapq import heapify, heappop, heappush

def is_prime(n):
    for i in range(2, int(pow(n, 0.5))+1):
        if n % i == 0:
            return False

    return True


def solve():
    X = II()

    while 1:
        if is_prime(X):
            print(X)
            return

        X += 1



if __name__ == '__main__':
    solve()
# Original solution
# coding: utf-8
from bisect import bisect_left
def primes(n):
    is_prime = [True] * (n + 1)
    is_prime[0] = False
    is_prime[1] = False
    for i in range(2, int(n**0.5) + 1):
        if not is_prime[i]:
            continue
        for j in range(i * 2, n + 1, i):
            is_prime[j] = False
    return [i for i in range(n + 1) if is_prime[i]]
X = int(eval(input()))
L = primes(10**6)
idx = bisect_left(L, X)
print((L[idx]))

# Optimized solution
# coding: utf-8
def elatostenes(x):
    for i in range(2, int(x ** 0.5)+1):
        if x % i == 0:
            return False
    return True

X = int(eval(input()))
while True:
    if elatostenes(X):
        print(X)
        exit()
    else:
        X += 1
# Original solution
a = int(eval(input()))
def hantei(x):
    k = 0
    for i in range(2, x//2):
        if x % i == 0:
            k += 1
    if k ==0:
        return x

c = True
while c:
    hantei(a)
    b = hantei(a)
    if b is not None:
        print(b)
        c = False
    elif b is None:
        a += 1

# Optimized solution
a = int(eval(input()))
b = True
def hantei(n, x): #素数だとFalseを返す
    for i in range(2, n):
        if n % i == 0:
            x = True
            return x
while b:
    b = hantei(a, b)
    if b is None:
        print(a)
        break
    a += 1
# Original solution
X=int(eval(input()))
while True:
    for x in range(2,X):
        if X%x==0:
            break
    else:
        print(X)
        break
    X+=1

# Optimized solution
X=int(eval(input()))
for x in range(X,2*X):
    for i in range(2,int(x**.5)+1):
        if x%i==0:
            break
    else:
        print(x)
        break
# Original solution
X=int(eval(input()))
num=2
while num<X:
    if X%num==0:
        X+=1
        num=2
    else:
        num+=1
print(X)

# Optimized solution
X=int(eval(input()))
for x in range(X,2*X):
    for i in range(2,int(x**.5)+1):
        if x%i==0:
            break
    else:
        print(x)
        break
# Original solution
import sys
#import numpy as np
stdin = sys.stdin

ri = lambda: int(rs())
rl = lambda: list(map(int, stdin.readline().split())) # applies to numbers only
rs = lambda: stdin.readline().rstrip()  # ignore trailing spaces

X = ri()
def primes(n):
    is_prime = [True] * (n + 1)
    is_prime[0] = False
    is_prime[1] = False
    for i in range(2, int(n**0.5) + 1):
        if not is_prime[i]:
            continue
        for j in range(i * 2, n + 1, i):
            is_prime[j] = False
    return [i for i in range(n + 1) if is_prime[i]]

l = set(primes(10**6))

while True:
    if X in l:
        print(X)
        exit()
    X += 1

# Optimized solution
import sys
sys.setrecursionlimit(10 ** 7)

sr = lambda: sys.stdin.readline().rstrip()
ir = lambda: int(sr())
lr = lambda: list(map(int, sr().split()))

X = ir()

def check(n):
    if X == 2:
        return True
    if n % 2 == 0:
        return False
    f = 3
    while f * f <= n:
        if n % f == 0:
            return False
        else:
            f += 2
    return True

while True:
    if check(X):
        print(X); exit()
    else:
        X += 1

# 44