Register Now

Login

Lost Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

What will be the output of the following Python code?
print(“Hello {1} and {0}”.format(‘bin’, ‘foo’))

What will be the output of the following Python code?
print(“Hello {1} and {0}”.format(‘bin’, ‘foo’))
a) Hello foo and bin
b) Hello bin and foo
c) Error
d) None of the mentioned

Answer: a
Explanation: The numbers 0 and 1 represent the position at which the strings are present.

Join The Discussion