require 'prime'
pr = []
Prime.each(10**6) do |i|
  pr.push(i)
end
pr_ch = Array.new(pr.length, 0)
n = gets.to_i
for i in 0..pr.length-1
  if n % pr[i] == 0
    while n % pr[i] == 0
      pr_ch[i] += 1
      n /= pr[i]
    end
  end
  if n == 1
    break
  end
end
ans = 1
count = 1
for i in 0..pr.length-1
  inst = 1
  if pr_ch[i] > 0
    for j in 1..pr_ch[i]
      inst += pr[i]**j
    end
    count *= pr_ch[i]+1
    ans *= inst
  end
end
ans -= count - 1
if pr_ch[0] > 0
  ans -= 2
end
puts ans
