The string.format()
method has this as part of its syntax.
print "{:>10}".format(case)
The number in the string tells python how many characters long the string should be, even if it's larger than the length of case
. And the greater than sign tells it to right justify case
within that space.