def round_3_1():
a1 = 2;
a2 = 3;
a3 = 1;
sum = a1 + a2 + a3;
for i in range(100):
s = i % sum;
if s < a1:
print("1");
elif s < a1 + a2:
print("2222");
else:
print("3333333");
round_3_1()
输出
1
1
2222
2222
2222
3333333
1
1
2222
2222
2222
3333333
标签:容器,sum,元素,2222,3333333,a1,a2,print,分配 From: https://www.cnblogs.com/kaibindirver/p/17663405.html