Contents Menu Expand Light mode Dark mode Auto light/dark, in light mode Auto light/dark, in dark mode Skip to content
toolbox documentation
toolbox documentation

Contents:

  • toolbox
  • MyST
  • My nifty title
  • Syntax Extensions
  • Log for How I am Bringing up This Repo and My New Server
  • Useful Commands
  • Common References
    • Python References

API Reference:

  • API Reference
    • apps.bazel_parser.cli
    • apps.bazel_parser.panel
    • apps.bazel_parser.parsing
    • apps.bazel_parser.refinement
    • apps.bazel_parser.repo_graph_data
    • apps.bazel_parser.repo_graph_data_test
    • examples.basic.client
    • examples.basic.grpc_test
    • examples.basic.hello_pb2
    • examples.basic.hello_pb2_grpc
    • examples.basic.hello_test
    • examples.basic.main
    • examples.basic.server
Back to top
View this page

Python References

Strings

https://docs.python.org/3/library/string.html#format-specification-mini-language

> # Format floating point number to two decimal places
> print('{:.2f}'.format(2.123))
2.12
> # Make width = 6 characters, continue to format

> print('{:06f}'.format(2.123))
002.12
Next
API Reference
Previous
Common References
Copyright © 2024, Michael Christen
Made with Sphinx and @pradyunsg's Furo
On this page
  • Python References
    • Strings