Problem:


Score: 200 points

Problem Statement

The number 105 is quite special - it is odd but still it has eight divisors.
Now, your task is this: how many odd numbers with exactly eight positive divisors are there between 1 and N (inclusive)?

Constraints

N is an integer between 1 and 200 (inclusive).

Input

Input is given from Standard Input in the following format:

N

Output

Print the count.

Sample Input 1

105

Sample Output 1

1

Among the numbers between 1 and 105, the only number that is odd and has exactly eight divisors is 105.

Sample Input 2

7

Sample Output 2

0

1 has one divisor. 3, 5 and 7 are all prime and have two divisors. Thus, there is no number that satisfies the condition.



Sample input:
105


Sample output:
1

Submission status: Wrong Answer

Solution code:
N = int(input())
if   N < 105:print(0)
elif N < 135:print(1)
else: print(2)

Submission status: Wrong Answer

Solution code:
N = int(input())
print(1) if N <=105 else print(0)

Submission status: Wrong Answer

Solution code:
n=int(input())
x=0
for i in range(1,n+1,2):
  c=0
  for j in range(1,n//2+1):
    if(i%j==0):c+=1
  if(c==8):x+=1
print(x)

Submission status: Wrong Answer

Solution code:
n=int(input())
if(n==105):print(1)
else:print(0)

Submission status: Wrong Answer

Solution code:
n=int(input())
if(n<105):print(0)
elif(n==105):print(1)
else:print(0)

Submission status: Wrong Answer

Solution code:
n=int(input())
if(n<105):print(0)
else:print(1)

Submission status: Wrong Answer

Solution code:
N=int(input())
count=0
answer=0

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

print(answer)

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
n = int( input() )
if n < 105:
    print(0)
elif n >= 105 and n < 165:
    print(1)
elif n >= 165 and n < 195:
    print(2)
else:
    print(3)

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
n = int( input() )
if n%2 == 0:
    print(0)
else:
    if n < 105:
        print(0)
    elif n >= 105 and n < 165:
        print(1)
    elif n >= 165 and n < 195:
        print(2)
    else:
        print(3)

Submission status: Wrong Answer

Solution code:
n = int(input())
print(4 if n >= 189 else 3 if n >= 165 else 2 if n >= 135 else 1 if n >= 105 else 0)

Submission status: Wrong Answer

Solution code:
n = int(input())
print(3 if n >= 189 else 2 if n >= 135 else 1 if n >= 105 else 0)

Submission status: Wrong Answer

Solution code:
n = int(input())
print(4 if n >= 189 else 3 if n >= 135 else 2 if n >= 105 else 0)

Submission status: Wrong Answer

Solution code:
print(1 if int(input()) >= 105 else 0)

Submission status: Wrong Answer

Solution code:
#coding; utf-8
N = int(input())
if N >= 1 and N <= 200:
    for i in range(N):
        i += 1
        sum = 0
        count = 0
        if i%2 != 0:
            for j in range(i):
                j+=1
                if i%j==0:
                    count += 1
            if count == 8:
                sum += 1
        else:
            continue
    print(sum)

Submission status: Wrong Answer

Solution code:
#coding; utf-8
N = int(input())
if N >= 1 and N <= 200:
    for i in range(N):
        sum = 0
        count = 0
        if (i+1)%2 != 0:
            #print(i)
            for j in range(i):
                #print(j)
                if i%(j+1)==0:
                    count += 1
            if count == 8:
                sum += 1
        else:
            continue
    print(sum)

Submission status: Wrong Answer

Solution code:
#coding; utf-8
N = int(input())
if N >= 1 and N <= 200:
    sum = 0
    for i in range(N):
        count = 0
        if i%2 != 0:
            #print(i)
            for j in range(i):
                #print(j)
                if i%(j+1)==0:
                    count += 1
            if count == 8:
                sum += 1
        else:
            continue
    print(sum)

Submission status: Wrong Answer

Solution code:
import sys

N = float(input())
t = 3
prime_number = []
while t <= N / 15.0:
    l = []
    for i in range(t+1):
        if i != 0:
            if t % i == 0:
                l.append(i)
    if l == [1, t]:
        prime_number.append(t)
    t += 1
n = len(prime_number)
ans = 0
if n < 3:
    print(0)
    sys.exit()
else:
    for i in prime_number:
        for j in prime_number:
            if j != i:
                for k in prime_number:
                    if k != i and k != j:
                        if i * j * k <= N:
                            ans += 1
ans = ans / 6
print(ans)
if N >= 189:
    ans += 2
elif N >= 135:
    ans += 1
print(int(ans))

Submission status: Wrong Answer

Solution code:
import math
import sys

N = float(input())
t = 3
prime_number = []
while t <= N / 15.0:
    l = []
    for i in range(t+1):
        if i != 0:
            if t % i == 0:
                l.append(i)
    if l == [1, t]:
        prime_number.append(t)
    t += 1
n = len(prime_number)
if n < 3:
    print(0)
    sys.exit()
else:
    ans = math.factorial(n) / (math.factorial(n-3) * math.factorial(3))
if N >= 189:
    ans += 2
elif N >= 135:
    ans += 1
print(int(ans))

Submission status: Wrong Answer

Solution code:
import math
import sys

N = float(input())
t = 3
prime_number = []
while t <= N / 15.0:
    l = []
    for i in range(t+1):
        if i != 0:
            if t % i == 0:
                l.append(i)
    if l == [1, t]:
        prime_number.append(t)
    t += 1
n = len(prime_number)
if n < 3:
    print(0)
    sys.exit()
else:
    ans = math.factorial(n) / (math.factorial(n-3+1) * math.factorial(3))
print(int(ans))

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
n = int(input())
total = 0
for i in range(1,n+1):
    if i % 2 ==0:continue
    count = 0
    for j in range(1,n+1):
        if count >8:
            total -= 1
            continue
        if i % j == 0:
            count +=1
        if count == 8 :
            total += 1
print(total)

Submission status: Wrong Answer

Solution code:
n = int(input())
d = [1] * (n + 1)
for i in range(2, n+1):
    for j in range(i, n+1, i):
        d[j] += 1
ans = 0
for i in range(1, n, 2):
  if d[i] == 8:
    ans += 1
 
print(ans)

Submission status: Wrong Answer

Solution code:
a=[105,161]
b= int(input())
print(len([i for i in a if i <= b]))

Submission status: Wrong Answer

Solution code:
#!/usr/bin/env python3
N = int(input())
a = [0] * 201
a[105] = a[135] = a[165] = a[195] = 1
for i in range(201):
    a[i] += a[i - 1]
print(a[N - (N % 2 == 0)])

Submission status: Wrong Answer

Solution code:
#!/usr/bin/env python3
N = int(input())
a = [0] * 201
a[105] = a[135] = a[165] = a[195] = 1
for i in range(201):
    a[i] += a[i - 1]
print(a[N])

Submission status: Wrong Answer

Solution code:
def main():
    N = int(input())
    result = 0
    for i in range(1, N + 1):
        count = 0
        for j in range(1, i+1):
            if i % j == 0:
                count += 1
        if count == 8 and i % 2 != 0:
            result += 1
    print(result)

Submission status: Wrong Answer

Solution code:
def f(n):
    return len([x for x in range(1, n+1) if (n % x == 0)])

def solve(n):
    return len([x for x in range(105, n+1) if (f(x) == 8)])

assert solve(105) == 1
assert solve(7) == 0
print solve(input())

Submission status: Wrong Answer

Solution code:
i = 1
j = 0

N = input()
N = int(N)

for i in range(1,N+1):	
	if i % 3 == 0:
		if i % 5 == 0:
			if i % 7 == 0:
				j = j + 1
	
print(j)

Submission status: Wrong Answer

Solution code:
n = int(input())
a = 0

for i in range(1, n+1, 2):
    c = 0  
   
    for j in range(1, i+1):
        print(i,j)
        if i % j == 0:
            c+=1
    if c == 8:
        a+=1

print(a)

Submission status: Wrong Answer

Solution code:
i = 1
j = 0

N = input()
N = int(N)

for i in range(0,N):
	if i % 3 == 0:
		if i % 5 == 0:
			if i % 7 == 0:
				j = j + 1
print(j)

Submission status: Wrong Answer

Solution code:

import math

N=int(input())
cc=0
for i in range(1,N+1):
    if i%2!=0:
        c=0
#        h=int(math.sqrt(i))
        for j in range(1,i+1):
            if N%j==0:
                c+=1
        if c==8:
            cc+=1
    else:
        continue
print(cc)

Submission status: Wrong Answer

Solution code:

import math

N=int(input())
cc=0
for i in range(1,N+1):
    if i%2!=0:
        c=0
        h=int(math.sqrt(i))
        for j in range(1,h+1):
            if N%j==0:
                c+=2
        if c==8:
            cc+=1
    else:
        continue
print(cc)

Submission status: Wrong Answer

Solution code:

import math

N=int(input())
cc=0
for i in range(1,N+1):
    c=0
    h=int(math.sqrt(i))
    for j in range(1,h+1):
        if N%j==0:
            c+=2
    if c==8:
        cc+=1
print(cc)

Submission status: Wrong Answer

Solution code:
n = int(input())

if n < 105: print(0)
elif n < 135: print(1)
elif n < 165: print(2)
elif n < 195: print(3)
else: print(4)

Submission status: Wrong Answer

Solution code:

# 値を渡すと約数の個数が返される
# num >= 2 であることは保障されている
def make_divisor_num(num):
    d_list = [1]
    for i in range(2, num // 2 + 1):
        if num % i == 0:
            d_list.append(i)
    d_list.append(num)
    return len(d_list)


N = int(input())
if N < 105:
    print(0)
    exit()


counter = 0
for num in range(105, N+1):
    if make_divisor_num(num) == 8:
        counter += 1

print(counter)

Submission status: Wrong Answer

Solution code:
N = int(input())

res = 0

for i in range(N)[1::2]:
    div = 0
    for j in range(i+1)[1:]:
        if i % j == 0:
            div += 1
    if div == 8:
        res += 1
        
print(res)

Submission status: Wrong Answer

Solution code:
a=int(input())
if a<105:print(0)
elif a>=195:print(2)
else: print(1)

Submission status: Wrong Answer

Solution code:
N = int(input())
R = 0
counter = 0
for i in range(1,N+1):
    R = N % i
    if R == 0:
        counter+=1
print(counter)

Submission status: Wrong Answer

Solution code:
n=int(input())
print(len([1 for x in range(1,n+1) if n%x==0]))

Submission status: Wrong Answer

Solution code:
import sys

# 関数 solve は，もちろん，問題に応じて書き換える
def solve(N):
    a= 0
    yakusuu_array=[]
    for x in range(1,N):
        if N%x == 0:
            yakusuu_array.append(x)
            a=len(yakusuu_array)+1

    if a==8 and N%2==1:
        return 1
    else :
        return 0
    

# ここから下は，入力・出力形式が同じであれば，変えなくて良い．
def readQuestion():
    line = sys.stdin.readline().rstrip()
    return int(line)

def main():
    n = readQuestion()
    answer = solve(n)
    print(answer)
    
if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
n=int(input())
print(1 if n>=105 and n%2!=0 else 0)

Submission status: Wrong Answer

Solution code:
print([[i%j==0 for j in range(1,i)].count(0) for i in range(1,int(input())+1,2)].count(7))

Submission status: Wrong Answer

Solution code:
N = int(input())

prime = [3, 5, 7, 11, 13]

# 約数が8個ということは、素因数分解した時の素因数の個数が0/7, 1/3, 1/1/1以外ありえない
zero_seven = 0
one_three = [a * (b ** 3) for a in prime for b in prime if a != b]
one_three = [i for i in one_three if i <= 200]
one_one_one = [a * b * c for a in prime for b in prime for c in prime
               if a != b and b != c and c != a]
one_one_one = [i for i in one_one_one if i <= 200]

ans = sorted(set(one_three + one_one_one))
i = 0
if ans[-1] <= N:
    print(len(ans))
    quit()
else:
    while ans[i] < N:
        i += 1
        if ans[i] > N:
            print(i)
            quit()

print(i)

Submission status: Wrong Answer

Solution code:
import sys

# 関数 solve は，もちろん，問題に応じて書き換える
def solve(N):
    yakusuu_array=[]
    for x in range(1,N):
        if N%x == 0:
            yakusuu_array.append(x)
            a=len(yakusuu_array)+1
            if a==8 and N%2==1 :
                return 1
            else:
                return 0

# ここから下は，入力・出力形式が同じであれば，変えなくて良い．
def readQuestion():
    line = sys.stdin.readline().rstrip()
    return int(line)

def main():
    n = readQuestion()
    answer = solve(n)
    print(answer)
    
if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
N=int(input())

yakusuu_array=[]
for x in range(1,N):
    if N%x == 0:
        yakusuu_array.append(x)
        a=len(yakusuu_array)+1
        if a==8 and N%2==1 :
            print('1')
        else:
            print('0')

Submission status: Wrong Answer

Solution code:
N = int(input())

def divlist(n):
    if n < 1:
        return []
    elif n == 1:
        return [1]
    else:
        div = [1]
        for i in range(2, n // 2 + 1):
            if n % i == 0:
                div.append(i)
        return div


ans = []

for i in range(1,N+1):
    if i % 2 == 0:
        pass
    elif len(divlist(i)) == 8:
        ans.append(i)

print(len(ans))

Submission status: Wrong Answer

Solution code:
N = 100

def divlist(n):
    if n < 1:
        return []
    elif n == 1:
        return [1]
    else:
        div = [1]
        for i in range(2, n // 2 + 1):
            if n % i == 0:
                div.append(i)
        return div


ans = []

for i in range(1,N+1):
    if i % 2 == 0:
        pass
    elif len(divlist(i)) == 8:
        ans.append(i)

print(len(ans))

Submission status: Wrong Answer

Solution code:
N = int(input())

def divlist(n):
    if n < 1:
        return []
    elif n == 1:
        return [1]
    else:
        div = [1]
        for i in range(2, n // 2 + 1):
            if n % i == 0:
                div.append(i)
        return div


ans = []

for i in range(1,N+1):
    if len(divlist(i)) == 8:
        ans.append(i)

print(len(ans))

Submission status: Wrong Answer

Solution code:
n = input()

num = int(n)
kisu_array = []
yakusuu_array = []
kazu_list = 0
for i in range(1,num+1):
    if i%2 != 0:
        kisu_array.append(i)

for i in kisu_array:
    for j in range(1,i+1):
        if i% j == 0:
            yakusuu_array += "1"
            if len(yakusuu_array) == 8:
                kazu_list += 1
                yakusuu_array = []

print(kazu_list)

Submission status: Wrong Answer

Solution code:
n = input()

num = int(n)
kisu_array = []
yakusuu_array = []
kazu_list = 0
for i in range(1,num+1):
    if i%2 != 0:
        kisu_array.append(i)

for i in kisu_array:
    for j in range(1,i+1):
        if i% j == 0:
            yakusuu_array += "1"
            if len(yakusuu_array) == 8:
                kazu_list += 1

print(kazu_list)

Submission status: Wrong Answer

Solution code:
n = input()

num = int(n)
kisu_array = []
yakusuu_array = []
kazu_list = 0
for i in range(1,num+1):
    if i%2 == 0:
        kisu_array.append(i)

for i in kisu_array:
    for j in range(1,i+1):
        if i% j == 0:
            yakusuu_array += "1"
            if yakusuu_array == "8":
                kazu_list += 1
                yakusuu_array = 0

print(kazu_list)

Submission status: Wrong Answer

Solution code:
def div(x):
    ans = 0
    for i in range(1, x + 1):
        if x % i == 0:
            ans += 1
    return ans
n = int(input())
ans = 0
for x in range(1, n + 1):
    if div(x) == 8:
        ans += 1
print(ans)

Submission status: Wrong Answer

Solution code:
n = input()

num = int(n)
kisu_array = []
yakusuu_array = []
kazu_list = 0
for i in range(1,num+1):
    if i%2 == 0:
        kisu_array.append(i)

for i in kisu_array:
    for j in range(1,i+1):
        if i% j == 0:
            yakusuu_array.append(i)
            if len(yakusuu_array) == 8:
                kazu_list += 1

print(kazu_list)

Submission status: Wrong Answer

Solution code:
import sys
n = int(input())
if n <= 104:
    print(0)
    sys.exit()
elif n <= 134:
    print(1)
    sys.exit()
elif n <= 164:
    print(2)
    sys.exit()
elif n <= 188:
    print(3)
    sys.exit()
else:
    print(4)

Submission status: Wrong Answer

Solution code:
N = int(input())

def factors(n):
    return sum(0 == n % (1 + x) for x in range(N))
print(sum(map(lambda x: factors(x) == 8, range(105, N+1))))

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
# coding: utf-8

# 素数を求める
import math
N = set(range(2,120))
p = []
while min(N) < 12:
    N = N - { min(N)*j for j in range(2,math.ceil(120/min(N))+1)}
    p.append(min(N))
    N.remove(min(N))
    
# 素数：2, 3, 5, 7, 11, 13, 17, 19,...
# 3*5*13<200<3*5*17なので、[3,5,7,11,13]で考える。

p = [3,5,7,11,13]
import itertools
import numpy
have8divisor = list(map(numpy.prod,list(itertools.combinations(p,3))))

n = int(input())
print(len(list(filter(lambda x : x <= n, have8divisor ))))

Submission status: Wrong Answer

Solution code:
n = int(input())
if n < 105:
    print(0)
elif n < 135:
    print(1)
elif n < 189:
    print(2)
else:
    print(3)

Submission status: Wrong Answer

Solution code:
import math

N = int(input())

ans = 0

def cal(n):
    limit = math.floor(math.sqrt(n))
    count = 0
    for i in range(1, limit+1):
        if n % i == 0:
            if i == limit:
                count += 1
            else:
                count += 2
    return count


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

print(ans)

Submission status: Wrong Answer

Solution code:
import math

N = int(input())

ans = 0

def cal(n):
    limit = math.floor(math.sqrt(n))
    count = 0
    for i in range(1, limit):
        if n % i == 0:
            if i == limit:
                count += 1
            else:
                count += 2
    return count


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

print(ans)

Submission status: Wrong Answer

Solution code:
# encoding: utf-8
N = int(input())

cnt = 0

# a = 8
# for base in range(2, N): cnt += int((2 * base - 1) ** 8 <= N)

# a = 4, b = 2
for base_a in range(2, N):
    M_a = (2 * base_a - 1) ** 3
    if M_a > N: break
    for base_b in filter(lambda x: x != base_a, range(2, N)):
        M_b = M_a * ((2 * base_b - 1) ** 1)
        if M_b > N: break
        else: cnt += 1
        
# a = b = c = 2
for base_a in range(2, N):
    M_a = (2 * base_a - 1) ** 1
    if M_a > N: break
    for base_b in range(base_a + 1, N):
        M_b = M_a * ((2 * base_b - 1) ** 1)
        if M_b > N: break
        for base_c in range(base_b + 1, N):
            M_c = M_b * ((2 * base_c - 1) ** 1)
            if M_c > N: break
            else: cnt += 1

print(cnt)

Submission status: Wrong Answer

Solution code:
import math

N = int(input())

ans = 0

def cal(n):
    limit = math.floor(math.sqrt(n))
    count = 0
    for i in range(1, limit):
        if n % i == 0:
            if i == limit:
                count += 1
            else:
                count += 2
    return count


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

print(ans)

Submission status: Wrong Answer

Solution code:
import math

N = int(input())

ans = 0

def cal(n):
    limit = math.floor(math.sqrt(n))
    count = 0
    for i in range(1, limit):
        if n % i == 0:
            if i == limit:
                count += 1
            count += 2
    return count


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

print(ans)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
n = input()
n = int(n)

if n <= 104:
    print(0)

elif n <= 134:
    print(1)

elif n <= 165:
    print(2)

elif n <= 188:
    print(3)

elif n <= 194:
    print(4)

else:
    print(5)

Submission status: Wrong Answer

Solution code:
l = [105,110,114,128,130,135,136,138,152,154,165,170,174,182,184,186,189,190,195,]

n = int(input())
cnt=0
for i in l:
    if i <= n:
        cnt += 1

print(cnt)

Submission status: Wrong Answer

Solution code:
# coding: utf-8

N = int(input())

if N < 105:
    print(0)
elif N < 135:
    print(1)
elif N < 165:
    print(2)
elif N < 195:
    print(3)
else:
    print(4)

Submission status: Wrong Answer

Solution code:
N = int(input())
if N >= 195:
    print("5")
elif N >= 185:
    print("4")
elif N >= 165:
    print("3")
elif N >= 135:
    print("2")
elif N >= 105:
    print("1")
else:
    print("0")

Submission status: Wrong Answer

Solution code:
N = int(input())
if N >= 195:
  print("4")
elif N >= 185:
  print("3")
elif N >= 165:
  print("2")
elif N >= 135:
  print("1")
else:
    print("0")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
n = int(input())
if n < 105:
    print(0)
elif n < 135:
    print(1)
elif n < 189:
    print(2)
else:
    print(3)

Submission status: Wrong Answer

Solution code:
from sys import stdin
def cnt(n):
 ans = 0
 for i in xrange(1,n+1):
  if n%i==0:
   ans+=1
 return ans
n = int(stdin.readline())
res = 0
for i in xrange(1,n+1):
 if cnt(i)==8:
  res+=1
print res

Submission status: Wrong Answer

Solution code:
N = int(input())
if N >= 195:
  print("3")
elif N >= 165:
  print("2")
elif N >= 105:
  print("1")
else:
  print("0")

Submission status: Wrong Answer

Solution code:
n=int(input())

if n<105:
  print(0)
if (n>=105)and(n<135):
  print(1)
if (n>=135)and(n<165):
  print(2)
if (n>=165)and(n<189):
  print(3)
if n>=189:
  print(4)

Submission status: Wrong Answer

Solution code:
n=int(input())

if n<105:
  print(0)
if (n>=105)and(n<135):
  print(1)
if (n>=135)and(n<165):
  print(2)
if (n>=165):
  print(3)

Submission status: Wrong Answer

Solution code:
n=int(input())

if n<105:
  print(0)
if (n<=105)and(n<165):
  print(1)
else:
  print(2)

Submission status: Wrong Answer

Solution code:
n=int(input())

if n<105:
  print(0)
else:
  print(1)

Submission status: Wrong Answer

Solution code:
N = int(input())
if N < 105:
  print(0)
elif 105 <= N < 155:
  print(1)
elif 155 <= N < 195:
  print(2)
else:
  print(3)

Submission status: Wrong Answer

Solution code:
N = int(input())
ans = 0
for x in range(N):
    if x % 2 == 1:
        tx = x
        ac, bc, cc = 0, 0, 0 
        a,b,c = False, False, False
        while (x % 2 == 0) or (x % 3 == 0) or (x % 5 == 0):
            if x % 2 == 0:
                ac += 1
                x = x // 2
                a = True
            elif x % 3 == 0:
                bc += 1
                x = x // 3
                b = True
            elif x % 5 == 0:
                cc += 1
                x = x // 5
                c = True
        count = (ac + 1) * (bc + 1) * (cc + 1)
        if count == 4:
            
            ans += 1
print(ans)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
N = int(input())

n = []
for i in range(1,N+1):
    if N % i == 0:
        n.append(i)

if len(n) == 8 and N % 2 != 0:
    print(1)
else:
    print(0)

Submission status: Wrong Answer

Solution code:
N = int(input().strip())
if N < 105:
    print(0)
elif N == 105:
    print(1)
else:
    print(1)

Submission status: Wrong Answer

Solution code:
a = int(input())
if a < 105:
 print("0")
elif a < 135:
 print("1")
elif a < 189:
 print("2")
else:
 print("3")

Submission status: Wrong Answer

Solution code:
N = int(input())

if N < 105:
    print(0)
elif N >= 105 and N < 135:
    print(1)
elif N >= 135 and N < 165:
    print(2)
elif N >= 165 and N < 195:
    print(3)
else:
    print(4)

Submission status: Wrong Answer

Solution code:
import math

N = int(input())
ans = 0
for i in range(1,N + 1,2):
    num = 0
    for j in range(1,int(math.sqrt(i))):
        if i % j == 0:
            num += 1
            if N != j ** 2:
                num += 1
    if num == 8:
        ans += 1
print(ans)

Submission status: Wrong Answer

Solution code:
N = int(input())

if N < 105:
    print(0)
elif N >= 105 and N < 135:
    print(1)
elif N >= 135 and N < 165:
    print(2)
else:
    print(3)

Submission status: Wrong Answer

Solution code:
import math

N=int(input())
cnt=0
num=0
for j in range(1,N+2,2):
    for i in range(1,j+1):
#        print(i)
#        print(j)
        if j%i==0 :
            cnt=cnt+1
    if cnt==8 :
#        print(cnt)
        num+=1
    cnt=0
#    print("---")
print(num)

Submission status: Wrong Answer

Solution code:
N = int(input())
x = []
res = 0
for i in range(3, N+1, 2):
    if len(x) == 0:
        x.append(i)
    else:
        y = i
        z = {}
        flag = True
        while flag:
            flag = False
            for j in x:
                if y % j == 0:
                    y /= j
                    z.setdefault(j, 0)
                    z[j] += 1
                    flag = True
        if y == i:
            x.append(i)
        else:
            yakusu = 1
            for j in z.values():
                yakusu *= j + 1
            if yakusu == 8:
                print(i)
                res += 1
print(res)

Submission status: Wrong Answer

Solution code:
# 整数の入力
#a = int(input())
# スペース区切りの整数の入力
#b, c = map(int, input().split( ))
# スペース区切りのリストの入力
#line = list(map(int, input().split( )))

Olympicvolunteer=int(input())


if Olympicvolunteer>=189:
    print(4)
elif Olympicvolunteer>=165:
    print(3)
elif Olympicvolunteer>=135:
    print(2)
elif Olympicvolunteer>=105:
    print(1)
else:
    print(0)

Submission status: Wrong Answer

Solution code:
num = int(input())
if num<105:
    print(0)
elif num>=105 and num<135:
    print(1)
elif num>=135 and num<165:
    print(2)
elif num>=165 and num<195:
    print(3)
elif num>=195 and num<199:
    print(4)
else:
    print(5)

Submission status: Wrong Answer

Solution code:
N = int(input())

if N < 105:
    print(0)
if N >= 105 and N < 135:
    print(1)
if N >= 135 and N < 165:
    print(2)
else:
    print(3)

Submission status: Wrong Answer

Solution code:
n = int(input())
if n < 105:
    print(0)
elif n in range(105, 135):
    print(1)
elif n in range(135, 165):
    print(2)
elif n in range(165, 189):
    print(2)
elif n in range(189, 195):
    print(3)
else:
    print(4)

Submission status: Wrong Answer

Solution code:
num = int(input())
if num<105:
    print(0)
elif num>=105 and num<135:
    print(1)
elif num>=135 and num<165:
    print(2)
elif num>=165 and num<195:
    print(3)
else:
    print(4)

Submission status: Wrong Answer

Solution code:
N = int(input())
if N >= 105:
  print(1)
elif N >= 135:
  print(2)
elif N >= 189:
  print(3)
else:
  print(0)

Submission status: Wrong Answer

Solution code:
N = int(input())

if N < 105:
    print(0)
if N >= 105 and N < 165:
    print(1)
else:
    print(2)

Submission status: Wrong Answer

Solution code:
n = int(input())
if n == 105:
    print(1)
elif n in range(1, 135):
    print(0)
elif n in range(135, 165):
    print(2)
elif n in range(165, 189):
    print(2)
elif n in range(189, 195):
    print(3)
else:
    print(4)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
n=int(input())
print(0 if n<105 else 1 if n<135 else 2 if n<165 else 3 if n<195 else 4)

Submission status: Wrong Answer

Solution code:
N = int(input())
if N > 105:
  print(1)
else:
  print(0)

Submission status: Wrong Answer

Solution code:
# 整数の入力
#a = int(input())
# スペース区切りの整数の入力
#b, c = map(int, input().split( ))
# スペース区切りのリストの入力
#line = list(map(int, input().split( )))

Olympicvolunteer=int(input())


if Olympicvolunteer>=189:
    print("4")
elif Olympicvolunteer>=165:
    print("3")
elif Olympicvolunteer>=135:
    print("2")
elif Olympicvolunteer>=105:
    print("1")
else:
    print("0")

Submission status: Wrong Answer

Solution code:
num = int(input())
if num<105 or num>200:
    print(0)
elif num>=105 and num<135:
    print(1)
elif num>=135 and num<165:
    print(2)
elif num>=165 and num<195:
    print(3)
elif num>=195 and num<199:
    print(4)
elif num==199 or num==200:
    print(5)

Submission status: Wrong Answer

Solution code:
num = int(input())
if num<105 or num>200:
    print(0)
elif num>=105 and num<135:
    print(1)
elif num>=135 and num<165:
    print(2)
elif num>=165 and num<195:
    print(3)
elif num>=195 and num<199:
    print(4)
elif num>=199 and num<=200:
    print(5)

Submission status: Wrong Answer

Solution code:
n=int(input())
print(0 if n<105 else 1 if n<135 else 2 if n<145 else 3 if n<195 else 4)

Submission status: Wrong Answer

Solution code:
from collections import Counter

N = int(input())

if N <= 2:
    print(0)
else:
    count = 0
    for ii in range(3, N+1, 2):
        s = ii
        num = []
        for jj in range(3, s+1, 2):
            if s % jj == 0:
                s = s // jj
                num.append(jj)
                break
        if s == 1:
            continue
        for jj in range(3, s+1, 2):
            if s % jj == 0:
                s = s // jj
                num.append(jj)
                break
        if s == 1:
            continue
        for jj in range(3, s+1, 2):
            if s % jj == 0:
                s = s // jj
                num.append(jj)
                break
        if s == 1:
            c = Counter(num)
            if len(c.keys()) == 3 and sum(list(c.values())) == 3:
                count += 1
            continue
        else:
            for jj in range(3, s+1, 2):
                if s % jj == 0:
                    num.append(jj)
                    break
            c = Counter(num)
            if len(c.keys()) == 2 and sum(list(c.values())) == 3:
                count += 1
            continue
    print(count)

Submission status: Wrong Answer

Solution code:
print(0 if int(input())<105 else 1)

Submission status: Wrong Answer

Solution code:
num = int(input())
if num<105 or num>200:
    print(0)
elif num>=105 and num<165:
    print(1)
elif num>=165 and num<195:
    print(2)
elif num>=195 and num<=200:
    print(3)

Submission status: Wrong Answer

Solution code:
N = int(input())

print(int(N >= 105))

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
def i1():
 return int(input())
def i2():
 return [int(i) for i in input().split()]
n=i1()
if n>=189:
   print(3)
elif n>=135:
   print(2)
elif n>=105:
   print(1)
else:
   print(0)

Submission status: Wrong Answer

Solution code:
num = int(input())
if num < 105 :
    print(0)
elif num>=105 and num<165:
    print(1)
elif num>=165 and num<195:
    print(2)
else :
    print(3)

Submission status: Wrong Answer

Solution code:
Olympicvolunteer=int(input())


if Olympicvolunteer>=189:
    print("4")
elif Olympicvolunteer>=165:
    print("3")
elif Olympicvolunteer>=135:
    print("2")
elif Olympicvolunteer>=105:
    print("1")
elif Olympicvolunteer>=50:
    Eiken=2
    Hoikuen=True
    print("0")
elif Olympicvolunteer==0:
    TokyoOlympic = False   #東京五輪0人 なにがいけなかったんでしょうねえ
    print("0")
else:
    print("0")