Examveda
Examveda

What will be the output of the following Python code?
s='{0}, {1}, and {2}'
s.format('hello', 'good', 'morning')

A. 'hello good and morning'

B. 'hello, good, morning'

C. 'hello, good, and morning'

D. Error

Answer: Option C


This Question Belongs to Python Program >> Formatting And Decorators

Join The Discussion

Related Questions on Formatting and Decorators