import scala.io.StdIn._
object Main extends App {
  val Array(n, m) = readLine.split(" ").map{_.toInt}
 
  val conditions = (1 to m).map{i => 
    readLine.split(" ").map{_.toInt}
  }
  // tle確認
println("Yes")
}