I'm trying to an item to my list:'pepperoni' by using append
.
pizza_vege=['tomato sauce','mushrooms','pepper','cheese','garlic powder']
print(pizza_vege)
pizza_peper=pizza_vege.append('peperoni')
print(pizza_peper) #The result here should show the list of pizza_vege and add 'pepperoni to it'
The result shown is:
['tomato sauce', 'mushrooms', 'pepper', 'cheese', 'garlic powder']
None
I don't understand why 'print
' returns 'None
' in output. Isn't it supposed to join the two sequences??
thank you all !