Code is executed with Pyodide, a port of CPython to WebAssembly/Emscripten. Some functionality in Python may not be available or may not work as expected.
# Fix the error in the code below
fruits = ["apple", "mango", "pear"]
favorite = fruits(1) # mango
print(favorite)
Click Run or press shift + ENTER to see the output below.