Append & Extend

0 votes
What is the difference between append() and extend()? When should they be used?
Jul 2, 2018 in Python by emerald
42 views

1 answer to this question.

0 votes
Hi.

This question has already been answered. Take a look https://www.edureka.co/community/5916/difference-between-append-vs-extend-list-methods-in-python?show=5916#q5916

Hope it helps :-)
answered Jul 2, 2018 by Nietzsche's daemon
• 4,260 points

Related Questions In Python

+1 vote
2 answers

Difference between append vs. extend list methods in Python

Python append() method adds an element to ...READ MORE

answered Aug 21 in Python by germyrinn
• 180 points
255 views
0 votes
1 answer

Difference between append vs. extend list methods in Python

append: Appends object at the end. x = ...READ MORE

answered Aug 8, 2018 in Python by bug_seeker
• 15,350 points
143 views
0 votes
1 answer

How do you append to a file?

with open("test.txt", "a") as myfile: myfile.write("appended text" ...READ MORE

answered Jul 27, 2018 in Python by Priyaj
• 56,920 points
35 views
+1 vote
1 answer

How to append an integer to a string?

You can not directly concatenate two different ...READ MORE

answered Aug 16, 2018 in Python by Omkar
• 67,660 points
61 views
0 votes
1 answer

How do I append one string to another in Python?

If you only have one reference to ...READ MORE

answered Oct 22, 2018 in Python by SDeb
• 13,180 points
49 views
+1 vote
2 answers

how can i count the items in a list?

Syntax :            list. count(value) Code: colors = ['red', 'green', ...READ MORE

answered Jul 6 in Python by Neha
• 330 points

edited Jul 8 by Kalgi 345 views
+4 votes
6 answers
0 votes
1 answer

Enlarging a list using functions using append() and extend()

Let me illustrate this with an example ...READ MORE

answered Jun 1, 2018 in Python by Nietzsche's daemon
• 4,260 points
19 views