Three poles stand evenly spaced along a line. Their heights are a, b and c meters, from left to right. We will call the arrangement of the poles _beautiful_ if the tops of the poles lie on the same line, that is, b-a = c-b.  Determine whether the arrangement of the poles is beautiful.
a,b,c=map(int,input().split())
print(["No","Yes"][a+c==b*2])

a,b,c=map(int,input().split())
print(["NO","YES"][a-b==b-c])
