peterverebics/CodeNet_Python_118 huggingface dataset:
def mkdiv(n):
    lower_divisors , upper_divisors = [], []
    i = 1
    while i*i <= n:
        if n % i == 0:
            lower_divisors.append(i)
            if i != n // i:
                upper_divisors.append(n//i)
        i += 1
    return lower_divisors + upper_divisors[::-1]
ans=0
n=int(input())

for i in range(n+1):
  if len(mkdiv(i))==8 and i%2:
    ans+=1
print(ans)
def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)

    return divisors


n = int(input())
count = 0

for i in range(1, n + 1):
    if i % 2 == 1 and len(make_divisors(i)) == 8:
        count += 1

print(count)
n = int(input())
res = 0
for i in range(1, n + 1, 2):
    temp = i
    cnt = 0
    for j in range(1, temp + 1):
        if temp % j == 0:cnt += 1
    
    if cnt == 8:res += 1
print(res)
x = int(input())
line = []
for i in range(1, x+1):
    count = 0
    if i%2 == 0:
        continue
    for j in range(1, i+1):
        if i%j == 0:
            count += 1
    if count == 8:
        line.append(i)
print(len(line))
n = int(input())
a = n//2
ans = 0
for j in range(1,n+1):
    count = 0
    for i in range(1,j+1):
        if j % i == 0:
            count += 1
        if count >= 8 and j % 2 == 1:
            ans +=1
print(ans)
N = int(input())

# dict = {i:0 for i in range(N)}
dict = {}
for i in range(N+1):
    if i % 2 == 1:
        dict[i] = 0
        for j in range(1, N+1):
            if i % j == 0:
                dict[i] += 1
            else:
                continue
    else:
        continue
# print(dict)
count = 0
for i in dict.values():
    if i == 8:
        count += 1
    else:
        continue

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

count = 0
for i in range(1, n+1):
  if i%2 == 1:
    tmp = 0
    for j in range(1, i+1):
      if i%j == 0:
        tmp+=1
    if tmp == 8:
      count+=1
print(count)
n = int(input())

def yak(n):
  lis = []
  for i in range(1,n+1):
    if n%i==0: lis.append(i)
  return lis

cnt = 0
for i in range(1, n+1):
  if i%2==1:
    l = len(yak(i))
    if l == 8:
      cnt += 1
      
print(cnt)
def make_divisors(n):
    lower_divisors , upper_divisors = [], []
    i = 1
    while i*i <= n:
        if n % i == 0:
            lower_divisors.append(i)
            if i != n // i:
                upper_divisors.append(n//i)
        i += 1
    return lower_divisors + upper_divisors[::-1]

N = int(input())
counter = 0
for i in range(1,N+1,2):
    if(len(make_divisors(i)) == 8):
        counter+=1
print(counter)
N = int(input())
ans = 0

for i in range(1,N+1,2):
    yakusuu = 0
    for j in range(1,i+1):
        if i%j == 0:
            yakusuu += 1
    if yakusuu == 8:
        ans +=1

print(ans)
#python3
from math import floor, sqrt

def f(x):
    p = set()
    for i in range(1, floor(sqrt(x))+1):
        if x%i == 0:
            p.add(i)
            p.add(x//i)
    return len(p)
def main():
    n = int(input())
    cnt = 0
    for i in range(1, n+1):
        if i%2 != 0:
            if f(i) == 8:
                cnt += 1
    print(cnt)
main()
N = int(input())
yakusu = 0
ans = 0
for i in range(1,N+ 1):
    if i % 2 == 1:
        yakusu = 0
        for i2 in range(1,i + 1):
            if i % i2 == 0:
                yakusu += 1
        if yakusu == 8:
            ans += 1
print(ans)
ans = 0
n = int(input())
for i in range(3,n+1,2):
  temp = 0
  for j in range(1,i+1):
    if i%j == 0:
      temp += 1
  ans += (1 if temp == 8 else 0)
print(ans)
n=int(input())

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

print(ans)
N = int(input())
a = 0

for i in range(1,1+N,2):
  b = 0
  for j in range(1,1+i,2):
    if i%j==0:
      b+=1
    if b==8:
      a+=1

print(a)
N = int(input())
c = 0
for  i in range(1,N+1):
  if i % 2 == 0:
    continue
  li = []
  if i < 10:
    continue
  else:
    k = i
    for j in range(2,int(i**(0.5)+3)):
      d = 1
      while k % j == 0:
        k = k/j
        d += 1
      if d != 1:
        li.append(d)
    ss = 1
    for x in li:
      ss *= x
    if ss == 8:
      #print(i)
      c += 1
    
print(c)
s = int(input())
if s <= 104:
  print(0)
elif 105<= s <135:
  print(1)
elif 135<= s <165:
  print(2)
elif 165 <= s <189:
  print(3)
elif 189<= s <195:
  print(4)
else:
  print(5)
n = int(input())
ans=0
for i in range(1,n+1,2):
    cnt = 0
    for j in range(1,n+1,2):
        if j>i:
            break
        if i%j==0:
            cnt+=1
    if cnt==8:
        ans+=1
print(ans)
N = int(input())

def div_count(i):
    count = 0
    for div in range(1, i+1):
        if i % div == 0:
            count += 1

    return count

ans = 0
for i in range(1, N+1, 2):
    if div_count(i) == 8:
        ans += 1

print(ans)
N=int(input())

s=0
for i in range(1,N+1,2):
  count=0
  for j in range(1,i+1):
    if i % j == 0:
      count+=1
  if count==8:
    s+=1

print(s)
n = int(input())

li = [3,5,7,11,13]
ans = 0
for i in range(1,n+1):
    cnt = 0
    for j in range(5):
        if i%li[j]==0:
            cnt += 1
    if cnt ==3:
        ans +=1

if n>=135:
    ans += 1
if n>=189:
    ans += 1

print(ans)
n = int(input())

def divisor(n):
    res = 0
    for i in range(1,int(n**0.5)+1):
        if n % i  == 0:
            res += 1
            if i != n//i:
                res += 1
    return res

ans = 0
for i in range(1, n+1, 2):
    if divisor(i) == 8:
        ans += 1
print(ans)
import sys

def resolve():
    N = int(input())
    cnt = 0
    for i in range(1, N+1, 2):
        if is_8_factors(i):
            cnt += 1
    print(cnt)

def is_8_factors(n):
    nfactors = 2
    upper = n
    div = 3
    while True:
        if upper <= div:
            break
        if n % div == 0:
            nfactors += 2
            upper = n // div
        div += 2

    return True if nfactors == 8 else False

if '__main__' == __name__:
    resolve()
n = int(input())
ans = 0
for num in range(1, n+1):
    if num%2 == 0:
        continue
    ls = []
    for i in range(1, num+1):
        if num%i == 0:
            ls.append(i)
    if len(ls) == 8:
        ans += 1
print(ans)
n=int(input())
l=[]
ans1=0
for i in range(1,n+1):
    if i%2!=0:
        l.append(i)
for j in range(len(l)):
    ans=0
    for k in range(1,l[j]+1):
        if l[j]%k==0:
            ans+=1
    if ans==8:
        ans1+=1
print(ans1)
n=int(input())
ans=0
for i in range(1,n+1):
  if i%2==0:continue
  cnt=0
  for j in range(1,i+1):
    if i%j==0:cnt+=1
  if cnt==8:ans+=1
print(ans)
N = int(input())

count = 0
for num in range(1, N+1):
    cnt = 0
    for i in range(1, num+1):
        if num%2==1 and num%i==0:
            cnt += 1
    if cnt >= 8:
        count += 1

print(count)
N=int(input())
if N<105:
  print(0)
  exit()
cnt=1
for i in range(107,N+1,2):
  tmp=0
  for j in range(1,N+1):
    if i%j==0:
      tmp+=1
  if tmp==8:
    cnt+=1
print(cnt)
def main(n):
    ans = 0

    for i in range(1, n + 1):
        if i % 2 == 0:
            continue

        l = 0
        for j in range(1, i + 1):

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

        if l == 8:
            ans += 1

    print(ans)


if __name__ == "__main__":
    n = int(input())

    main(n)
def main():
    n = int(input())
    r = 0
    for i1 in range(1, n + 1,2):
        cnt = 0
        for i2 in range(1,i1+1):
            cnt += i1 % i2 == 0
        r += cnt == 8
    print(r)

if __name__ == '__main__':
    main()
N = int(input())
def divisor(n):
    ans = []
    for i in range(1,int(n**0.5)+1):
        if n%i==0:
            ans.append(i)
            if n//i != i:
                ans.append(n//i)
    return len(ans)
ans = 0
for i in range(1,N+1,2):
    if divisor(i) == 8:
        ans += 1
print(ans)
import math
n = int(input())
ans = 0
if n > 104:
    for i in range(105,n+1)[::2]:
        cnt = 0
        for j in range(1,math.ceil(i**0.5)):
            if i%j == 0:
                cnt += 2
            if j**2 == i:
                cnt -= 1
        if cnt == 8:
            ans += 1
print(ans)
import sys
import os
import math

N=int(input())
count = 0

for i in range(1, N+1):
    if i % 2 == 0:
        continue
    else:
        yakusu = 0
        for j in range(1, i+1):
            if i % j == 0:
                yakusu += 1

    if yakusu == 8:
        count += 1

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

print(ans)
N = int(input())

def f(n):
  return sum(1  for i in range(1,n+1) if n % i ==0)

print(sum(1 for i in range(1,N+1) if i % 2 >0 and f(i)==8))
n = int(input())

ans = 0
for i in range(1, n+1):
    w = 0
    if i % 2 == 0:
        continue
    for j in range(1, i+1):
        if i % j == 0:
            w += 1
    if w == 8:
        ans += 1

print(ans)
N = int(input())

nums = range(1, N+1, 2)

res = 0
for n in nums:
    i = 1
    for x in range(1,n):
        if (n // (x)) * (x) == n:
            i = i + 1
    if i == 8:
        res += 1

print(res)
N = int(input())
ans = 0

for i in range(1, N+1):
  tmp = 0
  for j in range(1, N+1):
    if i % j == 0 and j % 2 == 1:
      tmp += 1
    
  if tmp == 8:
    ans += 1

print(ans)
N = int(input())
ret = 0
if N <= 105:
    if N == 105:
        print(1)
    else:
        print(0)
    exit()

ans = 1
for i in range(106, N+1):
    ret = 0
    for j in range(1, i+1):
        if i % j == 0:
            ret += 1
    if ret == 8 and i % 2 == 1:
        ans += 1
print(ans)
import math
n = int(input())

ans = 0

for i in range(1, n+1):
    if i % 2 == 0:
        continue
    num = 0
    for j in range(1, math.floor(i / 3) + 1):
        if i % j == 0:
            num += 1
    else:
        if num == 7:
            ans += 1

print(ans)
N = int(input())

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

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

        if cnt == 8:
            ans += 1
print(ans)
N = int(input())
ans = 0
for i in range(1, N + 1, 2):
  cnt = 0
  for j in range(1, i + 1):
    if i % j == 0:
      cnt += 1
  if cnt == 8:
    ans += 1
print(ans)
n = int(input())
def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)
    divisors.sort()
    return(divisors)
ans = 0
for i in range(1,n+1,2):
  if len(make_divisors(i)) == 8:
    ans += 1
print(ans)
def yakusuu(n):
    kosuu = 0
    for i in range(1, n+1 , 2):
        cnt = 0
        for j in range(1, n+1):
            if i % j == 0:
                cnt = cnt + 1
        if cnt == 8:
            kosuu = kosuu + 1
    return kosuu
    

def main():
    n = int(input())
    print(yakusuu(n))
    
if __name__ == '__main__':
    main()
def divisor(n): 
    i = 1
    table = []
    while i * i <= n:
        if n%i == 0:
            table.append(i)
            table.append(n//i)
        i += 1
    table = list(set(table))
    return table

N = int(input())
count = 0

for i in range(1,N+1,2):
    if len(divisor(i)) == 8:
        count += 1


print(count)
N = int(input())

result = 0
for i in range(1, N+1, 2):
    count = 0
    for j in range(1, i+1):
        if i % j == 0:
            count += 1
    if count == 8:
        result += 1

print(result)
import collections


def solve():

    N = int(input())

    def GetDivider(num):
        cnt = 0
        for i in range(1, num+1):
            if num % i == 0:
                cnt += 1

        return cnt

    ans = 0

    for i in range(1, N+1):
        if GetDivider(i) == 8:
            if i % 2 != 0:
                ans += 1

    print(ans)


if __name__ == "__main__":
    solve()
N = int(input())

ans = 0
for i in range(1, N+1, 2):
    divisor = []
    for j in range(1, N+1):
        if i % j == 0:
            divisor.append(j)
    
    if len(divisor) == 8:
        ans += 1

print(ans)
n = int(input())

a =[]

for i in range(1,n+1):
  if i % 2 == 1:
    a.append(i)
    
ans = 0
for j in a:
  x=0
  for k in range(1,j+1):
    if j % k == 0:
      x += 1
    if x ==8:
      ans += 1
    else:
      continue
      
      
print(ans)
n = int(input())

ans = 0

for i in range(1, n + 1, 2):
    cnt = 0
    for j in range(1,n+1):
        if i % j == 0:
            cnt += 1
            if cnt > 8:
                break
    if cnt == 8:
        ans +=1
        

print(ans)
n=int(input())
ans=0
for i in range(1,n+1):
    y=0
    for k in range(1,i+1):
        if i%k==0:
            y+=1
    if y==8 and i%2==1:
        ans+=1
print(ans)
N = int(input())

def count(x):
    c = 0
    for i in range(1, x + 1):
        if x % i == 0:
            c += 1
    return c

ans = 0
for i in range(3, N + 1, 2):
    if count(i) == 8:
        ans += 1
print(ans)
N = int(input())
cN = 0
for i in range(1,N+1,2):
    count = 0
    for j in range(1,i+1):
        if i%j == 0:
            count += 1
    if count == 8:
        cN += 1
print(cN)
n=int(input())
s=0
for i in range(1,n+1,2):
    c=0
    for  j in range(1,n+1):
        if(i%j==0):
            c+=1
    if(c==8):
        s+=1
print(s)
N = int(input())

count = 0
total_count = 0

for i in range(1,N+1):
    for j in range(1,N+1):
        if i % j == 0:
            count += 1
    if count == 8 and i % 2 == 1:
        total_count += 1
    count = 0
print(total_count)
n=int(input())
list=[]
for i in range(1,n+1,2):
	count=0
	for j in range(1,i+1,1):
		if i%j==0:
			count+=1
	if count==8:
		list.append(i)
print(len(list))
ii = lambda : int(input())
mi = lambda : map(int,input().split())
li = lambda : list(map(int,input().split()))

n = ii()

cnt = 0
for i in range(n,16,-1):
    if(i % 2 == 0):
        continue

    cnt2 = 0
    for j in range(3,i+1):
        if(i%j == 0):
            cnt2 +=1
    
    if cnt2 == 7:
        cnt += 1

print(cnt)
def make_divisors(n):
    lower_divisors , upper_divisors = [], []
    i = 1
    while i*i <= n:
        if n % i == 0:
            lower_divisors.append(i)
            if i != n // i:
                upper_divisors.append(n//i)
        i += 1
    return lower_divisors + upper_divisors[::-1]
  
N = int(input())

ans = 0
for i in range(1, N+1, 2):
    if len(make_divisors(i))==8:
        ans += 1
        
print(ans)
n = int(input())
ans = 0
for i in range(1,n+1,2):
    count = 0
    for j in range(1,i+1):
        if i%j==0:
            count += 1
    if count == 8:
        ans += 1
print(ans)
n=int(input())
cnt=0

def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)
    # divisors.sort()
    return divisors

for i in range(1,n+1,2):
  if len(make_divisors(i))==8:
    cnt+=1
print(cnt)
N = int(input())
ans = 0
for i in range(1,N+1,2):
  cnt = 0
  for j in range(1,i+1):
    if i%j==0:
      cnt += 1
  if cnt == 8:
    ans += 1
print(ans)
S=int(input())
count=0
 
for i in range(1,S+1,2):
    a=0
    for j in range(1,i+1):
        if i % j ==0:
            a+=1
    if a==8:
        count+=1
print(count)
l = [3*5*7, 3*5*11, 3*5*13, 3**3*5, 3**3*7]

n = int(input())
ans = 0
for i in l:
    if i <= n:
        ans += 1
print(ans)
n = int(input())
cnt = 0
def sympy(num):
  l = []
  for i in range(1, num+1):
    for j in range(1, num+1):
      if (i % 2 != 0) and (i*j == num):
        l.append(i)
  return l
for i in range(1, n+1):
  l = sympy(i)
  if (i % 2 != 0) and (len(l) == 8):
    cnt += 1
print(cnt)
N = int(input())
ans = 0
for n in range(1, N+1):
    cnt = 0
    for i in range(1, n+1):
        if (n % i == 0) and (n % 2 == 1):
            cnt += 1
    if cnt == 8:
        ans += 1
print(ans)
n=int(input())
if 105<=n<135:
    print(1)
elif 135<=n<165:
    print(2)
elif 165<=n<189:
    print(3)
elif 189<=n<195:
    print(4)
elif 195<=n:
    print(5)
else:
    print(0)
n = int(input())
ans = 0
for j in range(1,n+1):
  if j %2 ==0:
    continue
  div = []
  for i in range(2,j+1):
    if j % i ==0:
      count = 0
      while j%i==0:
        j = j//i
        count += 1
      div.append(count)
    if j == 1:
      break
  if div == [1,1,1] or div == [1,3] or div ==[3,1]:
    ans += 1
    
print(ans)
import sys

n = int(sys.stdin.readline().rstrip("\n"))
count = 0
for num in range(27, n+1, 2):
    divisor = 1
    for p in range(1, num, 2):
        if num % p == 0:
            divisor += 1
    if divisor == 8:
        count += 1
print(count)
def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5) + 1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n // i)

    divisors.sort()
    return divisors

N = int(input())
ans = 0
for i in range(1, N + 1):
    if i % 2 == 1:
        if len(make_divisors(i)) == 8:
            ans += 1
print(ans)
N = int(input())

ans = 0

for i in range(1,N+1):
    count = 0
    if i%2 == 1:
        for j in range(1,i+1):
            if i%j == 0:
                count += 1
        if count == 8:
            ans += 1
    
print(ans)
N=int(input())

i=1
ans=0
while i<=N:
    j=1
    count=0
    while j<=i:
        count+=1*(i%j==0)
        j+=1
    ans+=1*(count==8)
    i+=2

print(ans)
n = int(input())

def f(x):
    count = 0
    for i in range(1,x+1):
        if x % i == 0:
            count += 1
    return count

ans = 0

for i in range(1,n+1):
    if f(i) == 8 and i % 2 == 1:
        ans += 1

print(ans)
n=int(input())

res=0

for i in range(1,n+1):
    cnt=0
    if i % 2==1:
        for j in range(1,i+1):
            if i % j==0:
                cnt+=1
        if cnt == 8:
            res+=1

print(res)
N = int(input())

if N >= 195:
    ans = 5
elif N >= 189:
    ans = 4
elif N >= 165:
    ans = 3
elif N >= 135:
    ans = 2
elif N >= 105:
    ans = 1
else:
    ans = 0

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

#[105,135,165,189,195]

if n<105: print(0)
elif n<135: print(1)
elif n<165: print(2)
elif n<189: print(3)
elif n<195: print(4)
else: print(5)
N = int(input())

ans = 0
for i in range(1, N+1, 2):
    num = 0
    for j in range(1, i+1):
        if i % j == 0:
            num += 1
    if num == 8:
        ans += 1

print(ans)
n=int(input())
def make_divisors(n):
    lower_divisors , upper_divisors = [], []
    i = 1
    while i*i <= n:
        if n % i == 0:
            lower_divisors.append(i)
            if i != n // i:
                upper_divisors.append(n//i)
        i += 1
    return lower_divisors + upper_divisors[::-1]

ans=0
for x in range(n+1):
  if x%2==1:
    
    s=make_divisors(x)
    if len(s)==8:
      ans+=1
    
print(ans)
n = int(input())
ans = 0
for i in range(1, n+1, 2):
    c = 0
    for j in range(1, i+1):
      if i%j==0:
        c += 1
    if c==8:
      ans += 1
print(ans)
N=int(input())
count = 0
count2 = 0
for i in range(1,N+1):
    #print(i,"i")
    for j in range(1,N+1):
        #print(j,"k")
        if i % j == 0 :
            count += 1
            #print(count,"count")
    if count == 8 and i%2 != 0:
        count2 += 1
    ans = count2
    count = 0
print(ans)
n = int(input())
cnt = 0
lista = [0] * (n + 1)
# 奇数のみ
for i in range(1, n + 1, 2):
    # 3 * 1, 3 * 3, 3 * 5...
    for j in range(i, n + 1, 2 * i):
        lista[j] += 1
for i in range(n + 1):
    if lista[i] == 8:
        cnt += 1
print(cnt)
n = int(input())
a = 0
for i in range(1,n+1,2):
  c = 0
  for j in range(1,n+1):
    if i%j == 0:
      c += 1
  if c == 8:
    a +=1
print(a)
def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)

    divisors.sort()
    return divisors
a=int(input())
b=0
for i in range(1,a+1,2):
    if len(make_divisors(i))==8:
        b+=1
print(b)
N = int(input())
def yakusuu(a):
    b = 0
    if a % 2 == 1:
        for i in range(1,a+1):
            if a % i == 0:
                b += 1
        return b
    else:
        return 0
ans = 0
for i in range(1,N+1):
    if yakusuu(i) == 8:
        ans += 1
print(ans)
import math
n = int(input())

def factors(a):
    b = int(math.sqrt(a))
    f = []
    for i in range(1, b+1):
        if a % i == 0:
            f.append(i)
            f.append(a//i)
    return len(f)

def solve():
    if n < 105:
        print(0)
        return
    ans = 0
    for i in range(105, n+1, 2):
        if factors(i) == 8:
           ans += 1
    print(ans)
solve()
N = int(input())


def f(v):
    cnt = 0
    for i in range(1, v + 1):
        if v % i == 0:
            cnt += 1
    return cnt


ans = 0
for i in range(1, N + 1, 2):
    if f(i) == 8:
        ans += 1
print(ans)
N = int(input())
ans = 0

for i in range(1, N+1, 2):
    divisor_num = 0
    for j in range(1, i+1):
        if i % j == 0:
            divisor_num += 1
    if divisor_num == 8:
        ans += 1
print(ans)
def solve(x):
    if x%2==0:return False
    res = 0
    for i in range(x):
        if x%(i+1)==0:res += 1
    return res == 8
n = int(input())
ans = 0
for i in range(n):
    if solve(i+1):ans+=1
print(ans)
n = int(input())
ans = 0
def ok(x):
    res = 0
    i = 1
    while i*i <= x:
        if x%i == 0:
            res+=1
            if i!=x//i:res+=1
        i+=1
        
    return res == 8
for i in range(1,n+1,2):
    ans+=ok(i)
print(ans)
N = int(input())
ans = 0

for i in range(1, N+1, 2):
    count = 1
    for j in range(1, int(i/2)+2, 2):
        if (i/j).is_integer():
            count += 1

    if count == 8:
        ans += 1

print(ans)
def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n//i)
    return divisors

def main():
    n = int(input())
    cnt = 0
    for i in range(1,n+1,2):
        if len(make_divisors(i)) == 8:
            cnt+=1
    print(cnt)

if __name__ == '__main__':
    main()
n = int(input())
ans = 0

if n >= 105:
    for i in range(105, n+1, 2):
        count_yakusuu = 0
        for j in range(1, int(i**0.5)+1):
            if i % j == 0:
                count_yakusuu += 2
        if count_yakusuu == 8:
            ans += 1
print(ans)
N=int(input())
ans=0
for i in range(1,N+1,2):
    div=0
    for j in range(1,i+1):
        if i%j==0:
            div=div+1
    if div==8:
        ans+=1
print(ans)
N = int(input())
ans = 0
for n in range(1,N+1,2):
    sm = sum(n%i==0 for i in range(1,n+1))
    if sm==8:
        ans += 1
print (ans)
N = int(input())

ans = 0
for i in range(1, N + 1, 2):
  count = 0
  for j in range(1, i +1):
    if i % j == 0:
      count += 1
  if count == 8:
    ans += 1

print(ans)
# B
# 2020/03/09  0:11-
n = int(input())

def yakusu(x):
    l = []
    for i in range(1, x+1):
        if x%i == 0:
            l.append(i)
    return l

count = 0
for i in range(1, n+1):
    A = yakusu(i)
    if len(A) == 8 and i%2 == 1:
        count += 1
        
print(count)