adplus-dvertising
frame-decoration

Question

The output of the code shown below is:
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

Posted under Python

Answer: (c).‘hello, good, and morning’

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. The output of the code shown below is: