object Main extends App {
  val sc = new java.util.Scanner(System.in)
//  val l = List.fill(3)(sc.nextInt)
  val r, g, b = sc.next

  val ans = if ((r + g + b).toInt % 4 == 0) "YES" else "NO"
  println(ans)
}