#include <bits/stdc++.h>   using std::cin;   using std::cout;   using std::endl;   const int maxn = 200005;   long long a[maxn], b[maxn];   int n;   int ans, base;   std::map<std::pair<long long, long long>, int> mmp;   long long gcd(long long x, long long y) { return y == 0 ? x : gcd(y, x % y); }   int main() {     cin >> n;     for (int i = 1; i <= n; i++) cin >> a[i];     for (int i = 1; i <= n; i++) cin >> b[i];     for (int i = 1; i <= n; i++) {       if (a[i] == 0) {         if (b[i] == 0) base++;       } else {         long long temp1 = b[i], temp2 = a[i];         if (temp1 < 0)           temp1 = -temp1, temp2 = -temp2;         else if (temp1 == 0)           temp2 = 0;         long long g = gcd(llabs(temp1), llabs(temp2));         if (g) temp1 /= g, temp2 /= g;         mmp[std::make_pair(temp1, temp2)]++;       }     }     for (auto it : mmp) {       ans = std::max(ans, it.second);     }     cout << ans + base << endl;     return 0;   }   