代码示例:(标识:python_array_3)
python_array_3.py
cars = ["Porsche", "Volvo", "BMW"]

cars[0] = "Audi"

print(cars)
运行结果: