Examveda

What will be the output of the following Python code?
print("Hello {0!r} and {0!s}".format('foo', 'bin'))

A. Hello foo and foo

B. Hello 'foo' and foo

C. Hello foo and 'bin'

D. Error

Answer: Option B


This Question Belongs to Python Program >> Strings In Python

Join The Discussion

Related Questions on Strings in Python