format a float when printing pythong code example Example: float print format python print("x = {:.2f}".format(x))