class Problem
  attr_accessor :a, :b, :n, :m, :h, :w, :x, :y, :s ,:t

  def initialize
    @n = gets.to_s.to_i
  end

  def solve
    1.upto(9) do |i|
      1.upto(9) do |j|
        return true if i * j == n
      end
    end
    false
  end

  def show(ans)
    puts ans ? "Yes" : "No"
  end
end

Problem.new.instance_eval do
  show(solve)
end
