n=int(eval(input()))

a=[3,5,7,9,11,13,17,19]



count=0

for i in range(len(a)):

  for j in range(i+1,len(a)):

    for k in range(j+1,len(a)):

      if a[i]*a[j]*a[k]<=n:

        count+=1



print(count)
n=int(eval(input()))

ans=0

for i in range(1,n+1):

  cnt=0

  if i%2==0:continue

  for j in range(1,i+1):

    if i%j==0:cnt+=1

  if cnt==8:

    ans+=1

print(ans)
n = int(eval(input()))
a = [3, 5, 7, 9, 11, 13, 17, 19]
count = 0
for i in range(len(a)):
    for j in range(i + 1, len(a)):
        for k in range(j + 1, len(a)):
            if a[i] * a[j] * a[k] <= n:
                count += 1
print(count)

n = int(eval(input()))
ans = 0
for i in range(1, n + 1):
    cnt = 0
    if i % 2 == 0:
        continue
    for j in range(1, i + 1):
        if i % j == 0:
            cnt += 1
    if cnt == 8:
        ans += 1
print(ans)

-a = [3, 5, 7, 9, 11, 13, 17, 19] -count = 0 -for i in range(len(a)): -    for j in range(i + 1, len(a)): -        for k in range(j + 1, len(a)): -            if a[i] * a[j] * a[k] <= n: -                count += 1 -print(count) +ans = 0 +for i in range(1, n + 1): +    cnt = 0 +    if i % 2 == 0: +        continue +    for j in range(1, i + 1): +        if i % j == 0: +            cnt += 1 +    if cnt == 8: +        ans += 1 +print(ans)