-->
当前位置:首页 > 题库

PROGRAMMING:The smallest positive integer of small h

Luz5年前 (2021-05-10)题库396
Given an array a containing N integers, please find the smallest positive integer that never appears in the array
###Input format:
In the first line, enter $$n (1 / Le n / Le 10 ^ 6) $, and in the second line, enter n integers $$a separated by spaces_ i (-10^{18} \le Ai \le 10^{18})$$
###Output format:
Output an integer: the smallest positive integer that never appears in the array
###Input example:
```in
four
-5 3 2 3
```
###Output example:
The corresponding output is given here. For example:
```out
one
```







answer:If there is no answer, please comment