p02819 AtCoder Beginner Contest 149 - Next Prime
Find the minimum prime number greater than or equal to X.

Constraints

* 2 \le X \le 10^5
* All values in input are integers.

Input

Input is given from Standard Input in the following format:


X


Output

Print the minimum prime number greater than or equal to X.

Examples

Input

20


Output

23


Input

2


Output

2


Input

99992


Output

100003
```python
X=int(input())

for i in range(X,10**6):
  Flag=True
  for j in range(2,X):
    if i%j==0:
      Flag=False
      break
  if Flag==True:
    print(i)
    break
```