Python List extend() method

The list.extend() method extends the list by appending all the items from the iterable.

Syntax

Parameter

iterable: It is a required parameter which represents any iterable unlike list, set, tuple, etc.

Example 1

Output

Example 2

Output

Pin It on Pinterest

Share This