Examveda

What will be the output of the python code shown below for various styles of format specifiers?
x=1234
res='integers:...%d...%-6d...%06d' %(x, x, x)
res

A. 'integers:…1234…1234 …001234'

B. 'integers…1234…1234…123400'

C. 'integers:… 1234…1234…001234'

D. 'integers:…1234…1234…001234'

Answer: Option A


This Question Belongs to Python Program >> Formatting And Decorators

Join The Discussion

Related Questions on Formatting and Decorators