Answers for "extend keyword in python"

3

how to use extend in python

Non_living_things = ["cars","chair","wire extender "]
Non_living_things.extend(["Paper","Computer","Motherboard "])
print(Non_living_things)
Posted by: Guest on July-30-2021
3

python extend

fruits = ['apple', 'banana', 'cherry']
cars = ['Ford', 'BMW', 'Volvo']

fruits.extend(cars)

print(fruits)
# ['apple', 'banana', 'cherry', 'Ford', 'BMW', 'Volvo']
Posted by: Guest on April-15-2021

Python Answers by Framework

Browse Popular Code Answers by Language