String output format: %e, %f, %g and : Output Format « Development « Python
- Python
- Development
- Output Format
String output format: %e, %f, %g and

x = 1.23456789
print '%e | %f | %g' % (x, x, x)
print "%s" % x, str(x)
Related examples in the same category