for i in range(1, 10):
for j in range(1, i+1):
print '%s*%s=%s' % (j, i, i*j), # 逗号--不换行输出
print '' # 换行输出
转载于:https://blog.51cto.com/wmgchx/1287808
for i in range(1, 10):
for j in range(1, i+1):
print '%s*%s=%s' % (j, i, i*j), # 逗号--不换行输出
print '' # 换行输出
转载于:https://blog.51cto.com/wmgchx/1287808