Assume that an+1≥an+2 holds for some positive integers n. Since any positive integer i with ai≤an+2+c must also satisfy ai≤an+1+c, it follows that an≥an+1. Hence, if an<an+1 holds for some positive integer n, then an+1<an+2 follows, and by induction, we have an<an+1<an+2<an+3<….
Similarly, when an>an+1 holds for some positive integer n, we have an>an+1>an+2>…, especially an+d≤an−d for any non-negative integer d. This leads to a contradiction since an+an≤0.
Suppose that an=an+1 for all positive integers n. Then, as all integers i≥2 satisfy ai=a2≤a2+c, this contradicts the fact that there are exactly a1 positive integers i satisfying it. Therefore, there exists a positive integer k such that ak<ak+1, and from the above discussion, we have a1≤a2≤⋯≤ak<ak+1<ak+2<….
For integers n≥k, since any integer i>n+c+1 satisfies ai>an+c+1≥an+1+c, we have an≤n+c+1. Therefore, if we set bn=an−n (n≥k), then we have bn≤c+1 and bk≤bk+1≤bk+2≤…. Thus, there exist an integer d and an integer M≥k such that for n≥M, bn=d, i.e., an=n+d. Since a1≤a2≤⋯≤aM+c+1<aM+c+2<…, for any positive integer i, ai≤aM+1+c=aM+c+1 and i≤M+c+1 are equivalent. Therefore, aM=M+c+1, which is also equal to M+d, and for integers n≥M, we have an=n+c+1.
Suppose that for an integer N≥2, we have an=n+c+1 for all n≥N. Since a1≤a2≤⋯≤aN+c<aN+c+1<…, for any positive integer i, ai≤aN+c=aN+c and i≤N+c are equivalent. Therefore, aN−1=N+c.
Thus, by induction, we have an=n+c+1 for any positive integer n. This indeed satisfies the problem condition because ai≤an+1+c and i≤an are equivalent for any positive integer i.