n = int(input()) a = list(map(int,input().split())) b = list(map(int,input().split())) count = 0 for x,y in zip(a,b): if x <= y: count += 1 print(count)