51,733
社区成员
发帖
与我相关
我的任务
分享
代码如下:
import sys
M, S, T = map(int, input().split())
s1 = s2 = 0
for i in range(1, T + 1):
s1 += 17
if M >= 10:
s2 += 60
M -= 10
else:
M += 4
if s2 > s1:
s1 = s2
if s1 > S:
print(f"Yes\n{i}")
sys.exit()
print(f"No\n{s1}")