Help me in solving EQUALIZEAB problem

My issue

what’s the error in my code?
t=int(input())
for i in range(t):
a,b,x=map(int,input().split())
if a==b:
print(“YES”)
elif a<b:
c=a+x
d=abs(b-x)
if c==d:
print(“YES”)
else:
print(“NO”)
else:
e=abs(a-x)
f=b+x
if e==f:
print(“YES”)
else:
print(“NO”)

My code

# cook your dish here
t=int(input())
for i in range(t):
    a,b,x=map(int,input().split())
    if a==b: 
        print("YES")
    elif a<b:
        c=a+x
        d=abs(b-x)
        if c==d:
            print("YES")
        else:
            print("NO")
    else:
        e=abs(a-x)
        f=b+x
        if e==f:
            print("YES")
        else:
            print("NO")

Problem Link: Equalize AB Practice Coding Problem