1print tabulate([["pi",3.141593],["e",2.718282]], floatfmt=".2f")
2# -- ----
3# pi 3.14
4# e 2.71
5# -- ----
1>>> x = 13.949999999999999999
2>>> x
313.95
4>>> g = float("{:.2f}".format(x))
5>>> g
613.95
7>>> x == g
8True
9>>> h = round(x, 2)
10>>> h
1113.95
12>>> x == h
13True