# 入力された値を文字列で受け取る input = gets.chomp x, y, z = input.split.map{ _1.to_i } x * y * z % 3 == 0 ? puts("Yes") : puts("No")