x = gets.chomp.to_i
sosu = 0
for i in 1..x do
  count = 0
  for u in 1..i do
    if i % u == 0 then
      count = count + 1
      end
    end
  if count == 2 then
    sosu = sosu + 1
    end
  end
puts sosu