题解 | #百钱买百鸡问题#
百钱买百鸡问题
https://www.nowcoder.com/practice/74c493f094304ea2bda37d0dc40dc85b
for k in range(34): for j in range(100-3*k+1): if 100-3*k-j>=0: i=100-3*k-j if 5*i+3*j+k==100: res=[i,j,3*k] print(" ".join(str(i) for i in res)) else: break