n = int(input()) la = list(map(int,input().split())) lb = list(map(int,input().split())) c = 0 for i in range(n): if la[i] <= lb[i]: c += 1 print(c)