I've made a little script to calculator percent; however, I wish to actually include the %
within the message printed...
Tried this at the start - didn't work...
oFile.write("Percentage: %s%"
" % percent)
I then tried "Percentage: %s"%"
" % percent"
which didn't work.
I'd like the output to be:
Percentage: x%
I keep getting
TypeError: not all arguments converted during string formatting
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…