input() *a,=map(int, input().split()) *b,=map(int, input().split()) print(sum(c<=d for c, d in zip(a,b)))