A sample Python Program for Reference work ( Life Universe Everything )
- def main():
- while True:
- w=input()
- if w==42:
- break
- else :
- print w
- main()
-----------------------------------------------------------------------------------------=============================================================================================
I. Yet another A + B codeforces
def main():
a=int(input())
b=int(input())
c=int(input())
if a+b == c:
print("YES")
elif a+a == c:
print("YES")
elif b+b == c:
print("YES")
elif 2*c == b:
print("YES")
elif 2*a == b:
print("YES")
elif a+c == b:
print("YES")
elif 2*c == a:
print("YES")
elif 2*b == a:
print("YES")
elif c+b == a:
print("YES")
else:
print("NO")
main()
Comments
Post a Comment