$30
Create a linear linked list and implement a search algorithm to search through its values. Write
a menu-driven program that has the option to create a linked list by accepting user input integer
values, display the list and search for an element from the list.
Menu:
1. Add to the list
2. Display the list
3. Search from the list
4. Exit
For option 1, the program should accept any number of integer values from the user and continue
to prompt the user for values until they are done. For option 2, all the elements in the linked list
should be displayed. For option 3, the program should ask the user to enter a value to be searched
from the list. If the value is in the list, then it should display as “Element found”, otherwise
“Element not found” messages. The only option to exit from the program is through option 4.
Note: You need to define a linked list data structure with nodes having data and a pointer to the
next node.
Sample output:CSCI 161
Instructions:
• Preferred programming environment:
o OS
: Linux (Mint)
o Interpreter : Python 3 (not Python 2)
o Editor
: gedit or editor of your choice
• The program is saved as a file with .py extension.CSCI 161