AT_abc385_c [ABC385C] Illuminate Buildings
Description
There are $ N $ buildings arranged in a line at equal intervals. The height of the $ i $ -th building from the front is $ H_i $ .
You want to decorate some of these buildings with illuminations so that both of the following conditions are satisfied:
- The chosen buildings all have the same height.
- The chosen buildings are arranged at equal intervals.
What is the maximum number of buildings you can choose? If you choose exactly one building, it is considered to satisfy the conditions.
Input Format
The input is given from Standard Input in the following format:
> $ N $ $ H_1 $ $ \ldots $ $ H_N $
Output Format
Print the answer.
Explanation/Hint
### Sample Explanation 1
Choosing the 2nd, 5th, and 8th buildings from the front satisfies the conditions.
### Sample Explanation 2
Choosing just one building is considered to satisfy the conditions.
### Constraints
- $ 1 \leq N \leq 3000 $
- $ 1 \leq H_i \leq 3000 $
- All input values are integers.