#include <bits/stdc++.h>
using namespace std;
int n,x,dem=0,g=1,h=1,l=1,k=1;
int a[100005],b[100005],c[100005],d[100005];
int main()
{
    ios_base::sync_with_stdio(0);
    cin.tie(0);cout.tie(0);
    if(fopen("DANCING.INP","r"))
    {
        freopen("DANCING.INP","r",stdin);
        freopen("DANCING.OUT","w",stdout);
    }
    cin >> n;
    for(int i=1;i<=n;i++)
    {
        cin >> x;
        if(x<0)
        {
            a[g] = -x;
            g++;
        }
        if(x>0)
        {
            b[h] = x;
            h++;
        }
    }
    for(int i=1;i<=n;i++)
    {
        cin >> x;
        if(x<0)
        {
            c[l] = -x;
            l++;
        }
        if(x>0)
        {
            d[k] = x;
            k++;
        }
    }
    sort(a+1,a+g);
    sort(b+1,b+h);
    sort(c+1,c+l);
    sort(d+1,d+k);
    int i=1,j=1;
    while(i<g&&j<k)
    {
        if(a[i]>d[j])
        {
            dem++;
            j++;
        }
        i++;
    }
    i=1,j=1;
    while(i<h&&j<l)
    {
        if(c[j]>b[i])
        {
            dem++;
            i++;
        }
        j++;
    }
    cout << dem;
}
