the format specifier after the colons basically saysfrom left to rightfor values lower than onemake sure zero is displayed on the left side of the decimal pointshow two places after the decimalformat the input value as float we can also specify that each number should take up particular number of characters on the screen by placing value before the period in the precision this can be useful for outputting tabular datafor exampleorders [('burger' )('fries' )('cola' )print("product quantity price subtotal"for productpricequantity in orderssubtotal price quantity print("{ : }{ ^ ${ }formatproductquantitypricesubtotal)okthat' pretty scary looking format stringso let' see how it works before we break it down into understandable partsproduct quantity price subtotal burger $ fries $ cola $ niftysohow is this actually happeningwe have four variables we are formattingin each line in the for loop the first variable is string and is formatted with { : sthe means it is string variableand the means it should take up ten characters by defaultwith stringsif the string is shorter than the specified number of charactersit appends spaces to the right side of the string to make it long enough (bewarehoweverif the original string is too longit won' be truncated!we can change this behavior (to fill with other characters or change the alignment in the format string)as we do for the next valuequantity the formatter for the quantity value is { ^ dthe represents an integer value the tells us the value should take up nine characters but with integersinstead of spacesthe extra characters are zerosby default that looks kind of weird so we explicitly specify space (immediately after the colonas padding character the caret character tells us that the number should be aligned in the center of this available paddingthis makes the column look bit more professional the specifiers have to be in the right orderalthough all are optionalfill firstthen alignthen the sizeand finallythe type