Get your own Python server Result Size: 625 x 565
x
 
fruits = ["apple", "banana", "cherry", "kiwi", "mango"]
newlist = [x if x != "banana" else "orange" for x in fruits]
print(newlist)
['apple', 'orange', 'cherry', 'kiwi', 'mango']