Made a program to generate and traverse linked lists