0 votes
in Python by

What is the output of the following code?

v = 'Hello'

def f():

    v = 'World'

    return v

print(f())

print(v)

i) World

World

ii) Hello

Hello

iii) World

Hello

iv) Hello

World

1 Answer

0 votes
by
iii)

World

Hello

Related questions

0 votes
asked Dec 14, 2019 in Python by sharadyadav1986
0 votes
asked Jan 19, 2021 in Python by SakshiSharma
...