编程语言
首页 > 编程语言> > 洛谷(Python) P4956 [COCI2017-2018#6] Davor

洛谷(Python) P4956 [COCI2017-2018#6] Davor

作者:互联网

# 一共52周
week_num = 52
total_money = int(input())
week_money = total_money / week_num

flag = 1
for i in range(100,0,-1):
    for j in range(1,int(week_money)):
        if 7 * i + 21 * j == week_money:
            print(i)
            print(j)
            flag =0
            break
    if flag == 0:
        break

标签:week,Davor,洛谷,Python,money,52,break,flag,num
来源: https://blog.csdn.net/L_F_D/article/details/115042418