Jan-18-2017, 05:54 PM
Assuming each variable is to be formatted the same way, is there a way to avoid coding '${:,.0f}' in front of every variable that is to be printed on a line?
thanks
print(hdr62.format( '${:,.0f}'.format(ETE).rjust(12, ' '), '${:,.0f}'.format(ETFI).rjust(12, ' '), '${:,.0f}'.format(ETC).rjust(12, ' '), '${:,.0f}'.format(ETTA).rjust(12, ' '), '${:,.0f}'.format(ETFE).rjust(12, ' '), '${:,.0f}'.format(ETFFI).rjust(12, ' '), '${:,.0f}'.format(ETFC).rjust(12, ' ')))by the way, hdr62 is just a spacing format, like '{:>13}'
thanks