require 'bigdecimal'

n = gets
until n.nil?
 a = n.split
 x1 = a[0].to_f
 y1 = a[1].to_f
 x2 = a[2].to_f
 y2 = a[3].to_f
 x3 = a[4].to_f
 y3 = a[5].to_f
 x4 = a[6].to_f
 y4 = a[7].to_f

 x12 = BigDecimal(x1.to_s) - BigDecimal(x2.to_s)
 x34 = BigDecimal(x3.to_s) - BigDecimal(x4.to_s)
 y12 = BigDecimal(y1.to_s) - BigDecimal(y2.to_s)
 y34 = BigDecimal(y3.to_s) - BigDecimal(y4.to_s)
 
 if x12.to_f == 0.0 && y12.to_f == 0.0
  puts "NO"
 elsif x34.to_f == 0.0 && y34.to_f == 0.0
  puts "NO"
 elsif y12.to_f == 0.0
  if x34.to_f == 0.0 
   puts "YES"
  else
   puts "NO"
  end
 elsif y34.to_f == 0.0
  if x12.to_f == 0.0
   puts "YES"
  else
   puts "NO"
  end
 elsif x12.to_f == 0.0
  if y34.to_f == 0.0
   puts "YES"
  else
   puts "NO"
  end
 elsif x34.to_f == 0.0
  if y12.to_f == 0.0
   puts "YES"
  else
   puts "NO"
  end
 else
 ab = BigDecimal(x12.to_s) / BigDecimal(y12.to_s)
 cd = BigDecimal(x34.to_s) / BigDecimal(y34.to_s)
 ad = BigDecimal(ab.to_s) * BigDecimal(cd.to_s)
  if ad.to_f == -1.0
   puts "YES"
  else
   puts "NO"
  end
 end

 n = gets
end

