原题链接:PTA | 程序设计类实验辅助教学平台
Tips:以下Python代码仅个人理解,非最优算法,仅供参考!
T = int(input())
for i in range(1,T+1):
A,B,C= map(int,input().split())
if A+B>C:
print(f'Case #{i}: true')
else:
print(f'Case #{i}: false')
原题链接:PTA | 程序设计类实验辅助教学平台
Tips:以下Python代码仅个人理解,非最优算法,仅供参考!
T = int(input())
for i in range(1,T+1):
A,B,C= map(int,input().split())
if A+B>C:
print(f'Case #{i}: true')
else:
print(f'Case #{i}: false')