Print string at a fixed width 12 Apr 2020 a_string = "abc" fixed_string = "{0:>5}".format(a_string) print(f'|{fixed_string}|') | abc|