answered 13 years ago
See the printf-like python string formatting options here
updated 13 years ago
See the printf-like python string formatting options here. As an example:
sage: "%0.2f"%pi '3.14' sage: "%e"%pi '3.141593e+00'