------
## 最终结论
```python
def first_Missing_Positive(nums, n):
    # Create a set to track the positive numbers
    num_set = set(nums)
    
    # Iterate from 1 to n to find the first missing positive number
    for i in range(1, n + 1):
        if i not in num_set:
            return i
            
    # If all numbers from 1 to n are present, return n + 1
    return n + 1

# Test cases
assert first_Missing_Positive([1,2,3,-1,5],5) == 4
assert first_Missing_Positive([0,-1,-2,1,5,8],6) == 2
assert first_Missing_Positive([0,1,2,5,-8],5) == 3
```