解决python中TypeError: not enough arguments for format string
foriinrange(1,10):forjinrange(1,i+1):s=i*jprint('%d*%d='%i,j,s,end="\t")print("\t")如上一个九九乘法表的代码传参数时报错:TypeError:notenoughargumentsforformatstring将参数用括号括起后(如下所示),问题就解决了。print('%d*%d='%(i,j),s,end="