You can indent from 1 to any number, and if you do it with different numbers, you will get an error. Indent = space
With these, the character string and the character string can be combined.
print("xxx{}xxx".format(a))
print("xxx{1}xx{0}x".format(a,b))
print("xxx%sxx%sx"%(a,b))
print(f"xxx{b}xx{a}x")
Recommended Posts