E=[0]*(N:=int(input())+1) for p in range(2,N): if E[p]==0: for i in range(p,N,p): E[i]+=1 if i%(p*p) else 5 print(E.count(4))