Skip to content

Tag Archives: python-list

In python, lists are mutable as the elements of a list can be modified. But if you try to modify a value whose index is… Read More
Given two lists, the task is to write a Python program to remove all the common elements of two lists.  Examples: Input : list1 =… Read More
In this article, we will discuss how to filter a python list by using predicate. Filter function is used to filter the elements in the… Read More
Given a list, the task is to write a Python Program to get the indices of all occurrences of an element in a list. Method… Read More
In this article, we are going to see how to replace the value in a List using Python. We can replace values in the list… Read More
Given a list, the task is to write a Python Program to find the Index containing String. Example: Input: [‘sravan’, 98, ‘harsha’, ‘jyothika’, ‘deepika’, 78,… Read More
In this article, we will discuss how to convert a list of dictionaries to a dictionary of lists. Method 1: Using for loop By iterating… Read More
Python list() function takes any iterable as a parameter and returns a list. In Python iterable is the object you can iterate over. Some examples… Read More
In this article, we will discuss different ways to iterate the list of tuples in Python. It can be done in these ways: Using Loop.… Read More
In this article, we will discuss how to append the dictionary to the list data structure in Python. Here we will discuss: Appending a dictionary… Read More
In this article, we will discuss how to convert a List of tuples to multiple lists. We can convert lit of tuples to multiple lists… Read More
The Python’s List extend() method iterates over an iterable like string, list, tuple, etc., and adds each element of the iterable to the end of… Read More
The Python List append() method is used for appending and adding elements to the end of the List.  Syntax: list.append(item) Parameters: item: an item to… Read More
The Python List clear() method is used for removing all items from the List.  Syntax: list.clear() Parameters: The clear() method doesn’t take any parameters Returns:… Read More
In this article, we are going to discuss ways in which we can create a list of dictionaries in Python.  A list of dictionaries means,… Read More

Start Your Coding Journey Now!