require 'prime' n = gets.chomp.to_i a = (1..n).map {|i| i if n % i == 0 }.compact list = [] a.permutation(2) {|a, b| list.push(a.to_s << b.to_s) if a * b == n } b = n ** (1/2.0) if b * b == n list.push(b.to_s << b.to_s) end puts list.uniq.size