#include using namespace std; const int N = 110; int n, a[N]; void solve() { cin >> n; int ans = 0; for (int i = 1; i <= n; ++i) { int x; cin >> x; a[x]++; } for (int i = 1; i < 100; ++i) ans = max(ans, a[i] + a[i-1]); cout << ans << endl; } int main() { ios_base::sync_with_stdio(false); cin.tie(0); /// MULTITEST //int t; cin >> t; //while(t--) solve(); }