A, B, C = map(int, input().split()) if A % 3 == 0 or B % 3 == 0 or C % 3 == 0: print('Yes') else: print('No')