Python program to find the intersection of two lists

Editorial Staff - - Python Programming


Today we are going to share a Python Program to find the intersection of two lists. If you are a python beginner and want to start learning the python programming, then keep your close attention in this tutorial as I am going to share a Python Program to find the intersection of two lists.

Python Program to find the intersection of two lists code

python program and execute it with the help of python compiler. At the end of this tutorial, We have shared the output of below program.

Output:

Enter number of elements for list1:3
Enter number of elements for list2:4
For list1:
Enter element1:34
Enter element2:23
Enter element3:65
For list2:
Enter element1:33
Enter element2:65
Enter element3:23
Enter element4:86
The intersection is : [65, 23]

To increase your Python knowledge, practice all Python programs, here is a collection of 100+ Python problems with solutions.


About: Editorial Staff

Editorial Staff at FreeWebMentor is a team of professional developers leads by Prem Tiwari