The aim of this assignment is to implement and manipulate the basic operations related to Singly linked list and Doubly linked list data structures.

Assume that file1.txt and file2.txt contain unknown number of strings (text format). Write Java program that prints out all the strings that are in file1.txt but not in file2.txt. You have to store all the strings in file1.txt in a doubly linked list and all the strings in file2.txt in a singly linked list. Pseudo algorithm to do this task:

  • Read the strings/names in file1.txt and insert them into a doubly linked list.
  • Read the strings/names in file2.txt and insert them into a singly linked list.
  • Scan the singly linked list and for each string:
    • Remove all occurrences of this string from the doubly linked list.
  • Print out all the strings in the doubly linked list – five strings per line.
Academic Honesty!
It is not our intention to break the school's academic policy. Posted solutions are meant to be used as a reference and should not be submitted as is. We are not held liable for any misuse of the solutions. Please see the frequently asked questions page for further questions and inquiries.
Kindly complete the form. Please provide a valid email address and we will get back to you within 24 hours. Payment is through PayPal, Buy me a Coffee or Cryptocurrency. We are a nonprofit organization however we need funds to keep this organization operating and to be able to complete our research and development projects.